home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 7 / Amiga Format AFCD07 (Dec 1996, Issue 91).iso / serious / shareware / programming / emacs-complete / fsf / emacs / etc / lnews (.txt) < prev    next >
GNU Info File  |  1994-03-18  |  133KB  |  2,397 lines

  1. This is Info file LNEWS, produced by Makeinfo-1.54 from the input file
  2. news.texi.
  3. This file describes the new Lisp features of Emacs version 19 as first
  4. released to the public.  For Lisp changes in subsequent Emacs 19
  5. releases, see the file NEWS.
  6. New Features in the Lisp Language
  7. =================================
  8.    * The new function `delete' is a traditional Lisp function.  It takes
  9.      two arguments, ELT and LIST, and deletes from LIST any elements
  10.      that are equal to ELT.  It uses the function `equal' to compare
  11.      elements with ELT.
  12.    * The new function `member' is a traditional Lisp function.  It takes
  13.      two arguments, ELT and LIST, and finds the first element of LIST
  14.      that is equal to ELT.  It uses the function `equal' to compare
  15.      each list element with ELT.
  16.      The value is a sublist of LIST, whose first element is the one
  17.      that was found.  If no matching element is found, the value is
  18.      `nil'.
  19.    * The new function `indirect-function' finds the effective function
  20.      definition of an object called as a function.  If the object is a
  21.      symbol, `indirect-function' looks in the function definition of the
  22.      symbol.  It keeps doing this until it finds something that is not a
  23.      symbol.
  24.    * There are new escape sequences for use in character and string
  25.      constants.  The escape sequence `\a' is equivalent to `\C-g', the
  26.      ASCII BEL character (code 7).  The escape sequence `\x' followed
  27.      by a hexidecimal number represents the character whose ASCII code
  28.      is that number.  There is no limit on the number of digits in the
  29.      hexidecimal value.
  30.    * The function `read' when reading from a buffer now does not skip a
  31.      terminator character that terminates a symbol.  It leaves that
  32.      character to be read (or just skipped, if it is whitespace) next
  33.      time.
  34.    * When you use a function FUNCTION as the input stream for `read',
  35.      it is usually called with no arguments, and should return the next
  36.      character.  In Emacs 19, sometimes FUNCTION is called with one
  37.      argument (always a character).  When that happens, FUNCTION should
  38.      save the argument and arrange to return it when called next time.
  39.    * `random' with integer argument N returns a random number between 0
  40.      and N-1.
  41.    * The functions `documentation' and `documentation-property' now
  42.      take an additional optional argument which, if non-`nil', says to
  43.      refrain from calling `substitute-command-keys'.  This way, you get
  44.      the exact text of the documentation string as written, without the
  45.      usual substitutions.  Make sure to call `substitute-command-keys'
  46.      yourself if you decide to display the string.
  47.    * The new function `invocation-name' returns as a string the program
  48.      name that was used to run Emacs, with any directory names
  49.      discarded.
  50.    * The new function `map-y-or-n-p' makes it convenient to ask a series
  51.      of similar questions.  The arguments are PROMPTER, ACTOR, LIST,
  52.      and optional HELP.
  53.      The value of LIST is a list of objects, or a function of no
  54.      arguments to return either the next object or `nil' meaning there
  55.      are no more.
  56.      The argument PROMPTER specifies how to ask each question.  If
  57.      PROMPTER is a string, the question text is computed like this:
  58.           (format PROMPTER OBJECT)
  59.      where OBJECT is the next object to ask about.
  60.      If not a string, PROMPTER should be a function of one argument
  61.      (the next object to ask about) and should return the question text.
  62.      The argument ACTOR should be a function of one argument, which is
  63.      called with each object that the user says yes for.  Its argument
  64.      is always one object from LIST.
  65.      If HELP is given, it is a list `(OBJECT OBJECTS ACTION)', where
  66.      OBJECT is a string containing a singular noun that describes the
  67.      objects conceptually being acted on; OBJECTS is the corresponding
  68.      plural noun and ACTION is a transitive verb describing ACTOR.  The
  69.      default is `("object" "objects" "act on")'.
  70.      Each time a question is asked, the user may enter `y', `Y', or SPC
  71.      to act on that object; `n', `N', or DEL to skip that object; `!'
  72.      to act on all following objects; ESC or `q' to exit (skip all
  73.      following objects); `.' (period) to act on the current object and
  74.      then exit; or `C-h' to get help.
  75.      `map-y-or-n-p' returns the number of objects acted on.
  76.    * You can now "set" environment variables with the `setenv' command.
  77.      This works by setting the variable `process-environment', which
  78.      `getenv' now examines in preference to the environment Emacs
  79.      received from its parent.
  80. New Features for Loading Libraries
  81. ==================================
  82.    You can now arrange to run a hook if a particular Lisp library is
  83. loaded.
  84.    The variable `after-load-alist' is an alist of expressions to be
  85. evalled when particular files are loaded.  Each element looks like
  86. `(FILENAME FORMS...)'.
  87.    When `load' is run and the file name argument equals FILENAME, the
  88. FORMS in the corresponding element are executed at the end of loading.
  89. fILENAME must match exactly!  Normally FILENAME is the name of a
  90. library, with no directory specified, since that is how `load' is
  91. normally called.
  92.    An error in FORMS does not undo the load, but does prevent execution
  93. of the rest of the FORMS.
  94.    The function `eval-after-load' provides a convenient way to add
  95. entries to the alist.  Call it with two arguments, FILE and a form to
  96. execute.
  97.    The function `autoload' now supports autoloading a keymap.  Use
  98. `keymap' as the fourth argument if the autoloaded function will become
  99. a keymap when loaded.
  100.    There is a new feature for specifying which functions in a library
  101. should be autoloaded by writing special "magic" comments in that
  102. library itself.
  103.    Write `;;;###autoload' on a line by itself before the real
  104. definition of the function, in its autoloadable source file; then the
  105. command `M-x update-file-autoloads' automatically puts the `autoload'
  106. call into `loaddefs.el'.
  107.    You can also put other kinds of forms into `loaddefs.el', by writing
  108. `;;;###autoload' followed on the same line by the form.  `M-x
  109. update-file-autoloads' copies the form from that line.
  110. Compilation Features
  111. ====================
  112.    * Inline functions.
  113.      You can define an "inline function" with `defsubst'.  Use
  114.      `defsubst' just like `defun', and it defines a function which you
  115.      can call in all the usual ways.  Whenever the function thus defined
  116.      is used in compiled code, the compiler will open code it.
  117.      You can get somewhat the same effects with a macro, but a macro
  118.      has the limitation that you can use it only explicitly; a macro
  119.      cannot be called with `apply', `mapcar' and so on.  Also, it takes
  120.      some work to convert an ordinary function into a macro.  To
  121.      convert it into an inline function, simply replace `defun' with
  122.      `defsubst'.
  123.      Making a function inline makes explicit calls run faster.  But it
  124.      also has disadvantages.  For one thing, it reduces flexibility; if
  125.      you change the definition of the function, calls already inlined
  126.      still use the old definition until you recompile them.
  127.      Another disadvantage is that making a large function inline can
  128.      increase the size of compiled code both in files and in memory.
  129.      Since the advantages of inline functions are greatest for small
  130.      functions, you generally should not make large functions inline.
  131.      Inline functions can be used and open coded later on in the same
  132.      file, following the definition, just like macros.
  133.    * The command `byte-compile-file' now offers to save any buffer
  134.      visiting the file you are compiling.
  135.    * The new command `compile-defun' reads, compiles and executes the
  136.      defun containing point.  If you use this on a defun that is
  137.      actually a function definition, the effect is to install a
  138.      compiled version of that function.
  139.    * Whenever you load a Lisp file or library, you now receive a
  140.      warning if the directory contains both a `.el' file and a `.elc'
  141.      file, and the `.el' file is newer.  This typically indicates that
  142.      someone has updated the Lisp code but forgotten to recompile it,
  143.      so the changes do not take effect.  The warning is a reminder to
  144.      recompile.
  145.    * The special form `eval-when-compile' marks the forms it contains to
  146.      be evaluated at compile time *only*.  At top-level, this is
  147.      analogous to the Common Lisp idiom `(eval-when (compile) ...)'.
  148.      Elsewhere, it is similar to the Common Lisp `#.' reader macro (but
  149.      not when interpreting).
  150.      If you're thinking of using this feature, we recommend you
  151.      consider whether `provide' and `require' might do the job as well.
  152.    * The special form `eval-and-compile' is similar to
  153.      `eval-when-compile', but the whole form is evaluated both at
  154.      compile time and at run time.
  155.      If you're thinking of using this feature, we recommend you consider
  156.      whether `provide' and `require' might do the job as well.
  157.    * Emacs Lisp has a new data type for byte-code functions.  This makes
  158.      them faster to call, and also saves space.  Internally, a byte-code
  159.      function object is much like a vector; however, the evaluator
  160.      handles this data type specially when it appears as a function to
  161.      be called.
  162.      The printed representation for a byte-code function object is like
  163.      that for a vector, except that it starts with `#' before the
  164.      opening `['.  A byte-code function object must have at least four
  165.      elements; there is no maximum number, but only the first six
  166.      elements are actually used.  They are:
  167.     ARGLIST
  168.           The list of argument symbols.
  169.     BYTE-CODE
  170.           The string containing the byte-code instructions.
  171.     CONSTANTS
  172.           The vector of constants referenced by the byte code.
  173.     STACKSIZE
  174.           The maximum stack size this function needs.
  175.     DOCSTRING
  176.           The documentation string (if any); otherwise, `nil'.
  177.     INTERACTIVE
  178.           The interactive spec (if any).  This can be a string or a Lisp
  179.           expression.  It is `nil' for a function that isn't
  180.           interactive.
  181.      The predicate `byte-code-function-p' tests whether a given object
  182.      is a byte-code function.
  183.      You can create a byte-code function object in a Lisp program with
  184.      the function `make-byte-code'.  Its arguments are the elements to
  185.      put in the byte-code function object.
  186.      You should not try to come up with the elements for a byte-code
  187.      function yourself, because if they are inconsistent, Emacs may
  188.      crash when you call the function.  Always leave it to the byte
  189.      compiler to create these objects; it, we hope, always makes the
  190.      elements consistent.
  191. Floating Point Numbers
  192. ======================
  193.    You can now use floating point numbers in Emacs, if you define the
  194. macro `LISP_FLOAT_TYPE' when you compile Emacs.
  195.    The printed representation for floating point numbers requires
  196. either a decimal point surrounded by digits, or an exponent, or both.
  197. For example, `1500.0', `15e2', `15.0e2' and `1.5e3' are four ways of
  198. writing a floating point number whose value is 1500.
  199.    The existing predicate `numberp' now returns `t' if the argument is
  200. any kind of number--either integer or floating.  The new predicates
  201. `integerp' and `floatp' check for specific types of numbers.
  202.    You can do arithmetic on floating point numbers with the ordinary
  203. arithmetic functions, `+', `-', `*' and `/'.  If you call one of these
  204. functions with both integers and floating point numbers among the
  205. arguments, the arithmetic is done in floating point.  The same applies
  206. to the numeric comparison functions such as `=' and `<'.  The remainder
  207. function `%' does not accept floating point arguments, and neither do
  208. the bitwise boolean operations such as `logand' or the shift functions
  209. such as `ash'.
  210.    There is a new arithmetic function, `abs', which returns the absolute
  211. value of its argument.  It handles both integers and floating point
  212. numbers.
  213.    To convert an integer to floating point, use the function `float'.
  214. There are four functions to convert floating point numbers to integers;
  215. they differ in how they round.  `truncate' rounds toward 0, `floor'
  216. rounds down, `ceil' rounds up, and `round' produces the nearest integer.
  217.    You can use `logb' to extract the binary exponent of a floating
  218. point number.  More precisely, it is the logarithm base 2, rounded down
  219. to an integer.
  220.    Emacs has several new mathematical functions that accept any kind of
  221. number as argument, but always return floating point numbers.
  222. `cos'
  223. `sin'
  224. `tan'
  225.      Trigonometric functions.
  226. `acos'
  227. `asin'
  228. `atan'
  229.      Inverse trigonometric functions.
  230. `exp'
  231.      The exponential function (power of E).
  232. `log'
  233.      Logarithm base E.
  234. `log10'
  235.      Logarithm base 10
  236. `expt'
  237.      Raise X to power Y.
  238. `sqrt'
  239.      The square root function.
  240.    The new function `string-to-number' now parses a string containing
  241. either an integer or a floating point number, returning the number.
  242.    The `format' function now handles the specifications `%e', `%f' and
  243. `%g' for printing floating point numbers; likewise `message'.
  244.    The new variable `float-output-format' controls how Lisp prints
  245. floating point numbers.  Its value should be `nil' or a string.
  246.    If it is a string, it should contain a `%'-spec like those accepted
  247. by `printf' in C, but with some restrictions.  It must start with the
  248. two characters `%.'.  After that comes an integer which is the
  249. precision specification, and then a letter which controls the format.
  250.    The letters allowed are `e', `f' and `g'.  Use `e' for exponential
  251. notation (`DIG.DIGITSeEXPT').  Use `f' for decimal point notation
  252. (`DIGITS.DIGITS').  Use `g' to choose the shorter of those two formats
  253. for the number at hand.
  254.    The precision in any of these cases is the number of digits following
  255. the decimal point.  With `e', a precision of 0 means to omit the
  256. decimal point.  0 is not allowed with `f' or `g'.
  257.    A value of `nil' means to use the format `%.20g'.
  258.    No matter what the value of `float-output-format', printing ensures
  259. that the result fits the syntax rules for a floating point number.  If
  260. it doesn't fit (for example, if it looks like an integer), it is
  261. modified to fit.  By contrast, the `format' function formats floating
  262. point numbers without requiring the output to fit the syntax rules for
  263. floating point number.
  264. New Features for Printing And Formatting Output
  265. ===============================================
  266.    * The `format' function has a new feature: `%S'.  This print spec
  267.      prints any kind of Lisp object, even a string, using its Lisp
  268.      printed representation.
  269.      By contrast, `%s' prints everything without quotation.
  270.    * `prin1-to-string' now takes an optional second argument which says
  271.      not to print the Lisp quotation characters.  (In other words, to
  272.      use `princ' instead of `prin1'.)
  273.    * The new variable `print-level' specifies the maximum depth of list
  274.      nesting to print before cutting off all deeper structure.  A value
  275.      of `nil' means no limit.
  276. Changes in Basic Editing Functions
  277. ==================================
  278.    * There are two new primitives for putting text in the kill ring:
  279.      `kill-new' and `kill-append'.
  280.      The function `kill-new' adds a string to the front of the kill
  281.      ring.
  282.      Use `kill-append' to add a string to a previous kill.  The second
  283.      argument BEFORE-P, if non-`nil', says to add the string at the
  284.      beginning; otherwise, it goes at the end.
  285.      Both of these functions apply `interprogram-cut-function' to the
  286.      entire string of killed text that ends up at the beginning of the
  287.      kill ring.
  288.    * The new function `current-kill' rotates the yanking pointer in the
  289.      kill ring by N places, and returns the text at that place in the
  290.      ring.  If the optional second argument DO-NOT-MOVE is non-`nil',
  291.      it doesn't actually move the yanking point; it just returns the
  292.      Nth kill forward.  If N is zero, indicating a request for the
  293.      latest kill, `current-kill' calls `interprogram-paste-function'
  294.      (documented below) before consulting the kill ring.
  295.      All Emacs Lisp programs should either use `current-kill',
  296.      `kill-new', and `kill-append' to manipulate the kill ring, or be
  297.      sure to call `interprogram-paste-function' and
  298.      `interprogram-cut-function' as appropriate.
  299.    * The variables `interprogram-paste-function' and
  300.      `interprogram-cut-function' exist so that you can provide functions
  301.      to transfer killed text to and from other programs.
  302.    * The `kill-region' function can now be used in read-only buffers.
  303.      It beeps, but adds the region to the kill ring without deleting it.
  304.    * The new function `compare-buffer-substrings' lets you compare two
  305.      substrings of the same buffer or two different buffers.  Its
  306.      arguments look like this:
  307.           (compare-buffer-substrings BUF1 BEG1 END1 BUF2 BEG2 END2)
  308.      The first three arguments specify one substring, giving a buffer
  309.      and two positions within the buffer.  The last three arguments
  310.      specify the other substring in the same way.
  311.      The value is negative if the first substring is less, positive if
  312.      the first is greater, and zero if they are equal.  The absolute
  313.      value of the result is one plus the index of the first different
  314.      characters.
  315.    * Overwrite mode treats tab and newline characters specially.  You
  316.      can now turn off this special treatment by setting
  317.      `overwrite-binary-mode' to `t'.
  318.    * Once the mark "exists" in a buffer, it normally never ceases to
  319.      exist.  However, in Transient Mark mode, it may become "inactive".
  320.      The variable `mark-active', which is always local in all buffers,
  321.      indicates whether the mark is active: non-`nil' means yes.
  322.      When the mark is inactive, the function `mark' normally gets an
  323.      error.  However, `(mark t)' returns the position of the inactive
  324.      mark.
  325.      The function `push-mark' normally does not activate the mark.
  326.      However, it accepts an optional third argument ACTIVATE which, if
  327.      non-`nil', says to activate.
  328.      A command can request deactivation of the mark upon return to the
  329.      editor command loop by setting `deactivate-mark' to a non-`nil'
  330.      value.  Transient Mark mode works by causing the command loop to
  331.      take note of `deactivate-mark' and actually deactivate the mark.
  332.      Transient Mark mode enables highlighting of the region when the
  333.      mark is active.  This is currently implemented only under the X
  334.      Window System.  A few other commands vary their behavior slightly
  335.      in this case, by testing `transient-mark-mode'.  More
  336.      specifically, they avoid special display actions such as moving
  337.      the cursor temporarily, which are not needed when the region is
  338.      shown by highlighting.
  339.      The variables `activate-mark-hook' and `deactivate-mark-hook' are
  340.      normal hooks run, respectively, when the mark becomes active and
  341.      when it becomes inactive.  The hook `activate-mark-hook' is also
  342.      run at the end of a command if the mark is active and the region
  343.      may have changed.
  344.    * The function `move-to-column' now accepts a second optional
  345.      argument FORCE, in addition to COLUMN; if the requested column
  346.      COLUMN is in the middle of a tab character and FORCE is non-`nil',
  347.      `move-to-column' replaces the tab with the appropriate sequence of
  348.      spaces so that it can place point exactly at COLUMN.
  349.    * The search functions when successful now return the value of point
  350.      rather than just `t'.  This affects the functions
  351.      `search-forward', `search-backward', `word-search-forward',
  352.      `word-search-backward', `re-search-forward', and
  353.      `re-search-backward'.
  354.    * When you do regular expression searching or matching, there is no
  355.      longer a limit to how many `\(...\)' pairs you can get information
  356.      about with `match-beginning' and `match-end'.  Also, these
  357.      parenthetical groupings may now be nested to any degree.
  358.    * In a regular expression, when you use an asterisk after a
  359.      parenthetical grouping, and then ask about what range was matched
  360.      by the grouping, Emacs 19 reports just its last occurrence.  Emacs
  361.      18 used to report the range of all the repetitions put together.
  362.      For example,
  363.           (progn
  364.            (string-match "f\\(o\\)*" "foo")
  365.            (list (match-beginning 1)
  366.                  (match-end 1)))
  367.      returns `(2 3)' in Emacs 19, corresponding to just the last
  368.      repetition of `\(o\)'.  In Emacs 18, that expression returns `(1
  369.      3)', encompassing both repetitions.
  370.      If you want the Emacs 18 behavior, use a grouping *containing* the
  371.      asterisk: `"f\\(o*\\)"'.
  372.    * The new special form `save-match-data' preserves the regular
  373.      expression match status.  Usage: `(save-match-data BODY...)'.
  374.    * The function `translate-region' applies a translation table to the
  375.      characters in a part of the buffer.  Invoke it as
  376.      `(translate-region START END TABLE)'; START and END bound the
  377.      region to translate.
  378.      The translation table TABLE is a string; `(aref TABLE OCHAR)'
  379.      gives the translated character corresponding to OCHAR.  If the
  380.      length of TABLE is less than 256, any characters with codes larger
  381.      than the length of TABLE are not altered by the translation.
  382.      `translate-region' returns the number of characters which were
  383.      actually changed by the translation.  This does not count
  384.      characters which were mapped into themselves in the translation
  385.      table.
  386.    * There are two new hook variables that let you notice all changes
  387.      in all buffers (or in a particular buffer, if you make them
  388.      buffer-local): `before-change-function' and
  389.      `after-change-function'.
  390.      If `before-change-function' is non-`nil', then it is called before
  391.      any buffer modification.  Its arguments are the beginning and end
  392.      of the region that is going to change, represented as integers.
  393.      The buffer that's about to change is always the current buffer.
  394.      If `after-change-function' is non-`nil', then it is called after
  395.      any buffer modification.  It takes three arguments: the beginning
  396.      and end of the region just changed, and the length of the text that
  397.      existed before the change.  (To get the current length, subtract
  398.      the region beginning from the region end.)  All three arguments are
  399.      integers.  The buffer that has just changed is always the current
  400.      buffer.
  401.      Both of these variables are temporarily bound to `nil' during the
  402.      time that either of these hooks is running.  This means that if
  403.      one of these functions changes the buffer, that change won't run
  404.      these functions.  If you do want hooks to be run recursively,
  405.      write your hook functions to bind these variables back to their
  406.      usual values.
  407.    * The hook `first-change-hook' is run using `run-hooks' whenever a
  408.      buffer is changed that was previously in the unmodified state.
  409.    * The second argument to `insert-abbrev-table-description' is now
  410.      optional.
  411. Text Properties
  412. ===============
  413.    Each character in a buffer or a string can have a "text property
  414. list", much like the property list of a symbol.  The properties belong
  415. to a particular character at a particular place, such as, the letter
  416. `T' at the beginning of this sentence.  Each property has a name, which
  417. is usually a symbol, and an associated value, which can be any Lisp
  418. object--just as for properties of symbols.
  419.    You can use the property `face' to control the font and color of
  420. text.  Several other property names have special meanings.  You can
  421. create properties of any name and examine them later for your own
  422. purposes.
  423.    Copying text between strings and buffers preserves the properties
  424. along with the characters; this includes such diverse functions as
  425. `substring', `insert', and `buffer-substring'.
  426.    Since text properties are considered part of the buffer contents,
  427. changing properties in a buffer "modifies" the buffer, and you can also
  428. undo such changes.
  429.    Strings with text properties have a special printed representation
  430. which describes all the properties.  This representation is also the
  431. read syntax for such a string.  It looks like this:
  432.      #("CHARACTERS" PROPERTY-DATA...)
  433. where PROPERTY-DATA is zero or more elements in groups of three as
  434. follows:
  435.      BEG END PLIST
  436. The elements BEG and END are integers, and together specify a portion
  437. of the string; PLIST is the property list for that portion.
  438. Examining Text Properties
  439. -------------------------
  440.    The simplest way to examine text properties is to ask for the value
  441. of a particular property of a particular character.  For that, use
  442. `get-text-property'.  Use `text-properties-at' to get the entire
  443. property list of a character.
  444.    `(get-text-property POS PROP OBJECT)' returns the PROP property of
  445. the character after POS in OBJECT (a buffer or string).  The argument
  446. OBJECT is optional and defaults to the current buffer.
  447.    `(text-properties-at POS OBJECT)' returns the entire property list
  448. of the character after POS in the string or buffer OBJECT (which
  449. defaults to the current buffer).
  450. Changing Text Properties
  451. ------------------------
  452.    There are four primitives for changing properties of a specified
  453. range of text:
  454. `add-text-properties'
  455.      This function puts on specified properties, leaving other existing
  456.      properties unaltered.
  457. `put-text-property'
  458.      This function puts on a single specified property, leaving others
  459.      unaltered.
  460. `remove-text-properties'
  461.      This function removes specified properties, leaving other
  462.      properties unaltered.
  463. `set-text-properties'
  464.      This function replaces the entire property list, leaving no
  465.      vestige of the properties that that text used to have.
  466.    All these functions take four arguments: START, END, PROPS, and
  467. OBJECT.  The last argument is optional and defaults to the current
  468. buffer.  The argument PROPS has the form of a property list.
  469. Property Search Functions
  470. -------------------------
  471.    In typical use of text properties, most of the time several or many
  472. consecutive characters have the same value for a property.  Rather than
  473. writing your programs to examine characters one by one, it is much
  474. faster to process chunks of text that have the same property value.
  475.    The functions `next-property-change' and `previous-property-change'
  476. scan forward or backward from position POS in OBJECT, looking for a
  477. change in any property between two characters scanned.  They returns
  478. the position between those two characters, or `nil' if no change is
  479. found.
  480.    The functions `next-single-property-change' and
  481. `previous-single-property-change' are similar except that you specify a
  482. particular property and they look for changes in the value of that
  483. property only.  The property is the second argument, and OBJECT is
  484. third.
  485. Special Properties
  486. ------------------
  487.    If a character has a `category' property, we call it the "category"
  488. of the character.  It should be a symbol.  The properties of the symbol
  489. serve as defaults for the properties of the character.
  490.    You can use the property `face' to control the font and color of
  491. text.
  492.    You can specify a different keymap for a portion of the text by means
  493. of a `local-map' property.  The property's value, for the character
  494. after point, replaces the buffer's local map.
  495.    If a character has the property `read-only', then modifying that
  496. character is not allowed.  Any command that would do so gets an error.
  497.    If a character has the property `modification-hooks', then its value
  498. should be a list of functions; modifying that character calls all of
  499. those functions.  Each function receives two arguments: the beginning
  500. and end of the part of the buffer being modified.  Note that if a
  501. particular modification hook function appears on several characters
  502. being modified by a single primitive, you can't predict how many times
  503. the function will be called.
  504.    Insertion of text does not, strictly speaking, change any existing
  505. character, so there is a special rule for insertion.  It compares the
  506. `read-only' properties of the two surrounding characters; if they are
  507. `eq', then the insertion is not allowed.  Assuming insertion is
  508. allowed, it then gets the `modification-hooks' properties of those
  509. characters and calls all the functions in each of them.  (If a function
  510. appears on both characters, it may be called once or twice.)
  511.    The special properties `point-entered' and `point-left' record hook
  512. functions that report motion of point.  Each time point moves, Emacs
  513. compares these two property values:
  514.    * the `point-left' property of the character after the old location,
  515.      and
  516.    * the `point-entered' property of the character after the new
  517.      location.
  518. If these two values differ, each of them is called (if not `nil') with
  519. two arguments: the old value of point, and the new one.
  520.    The same comparison is made for the characters before the old and new
  521. locations.  The result may be to execute two `point-left' functions
  522. (which may be the same function) and/or two `point-entered' functions
  523. (which may be the same function).  The `point-left' functions are
  524. always called before the `point-entered' functions.
  525.    A primitive function may examine characters at various positions
  526. without moving point to those positions.  Only an actual change in the
  527. value of point runs these hook functions.
  528. New Features for Files
  529. ======================
  530.    * The new function `file-accessible-directory-p' tells you whether
  531.      you can open files in a particular directory.  Specify as an
  532.      argument either a directory name or a file name which names a
  533.      directory file.  The function returns `t' if you can open existing
  534.      files in that directory.
  535.    * The new function `file-executable-p' returns `t' if its argument
  536.      is the name of a file you have permission to execute.
  537.    * The function `file-truename' returns the "true name" of a
  538.      specified file.  This is the name that you get by following
  539.      symbolic links until none remain.  The argument must be an
  540.      absolute file name.
  541.    * New functions `make-directory' and `delete-directory' create and
  542.      delete directories.  They both take one argument, which is the
  543.      name of the directory as a file.
  544.    * The function `read-file-name' now takes an additional argument
  545.      which specifies an initial file name.  If you specify this
  546.      argument, `read-file-name' inserts it along with the directory
  547.      name.  It puts the cursor between the directory and the initial
  548.      file name.
  549.      The user can then use the initial file name unchanged, modify it,
  550.      or simply kill it with `C-k'.
  551.      If the variable `insert-default-directory' is `nil', then the
  552.      default directory is not inserted, and the new argument is ignored.
  553.    * The function `file-relative-name' does the inverse of
  554.      expansion--it tries to return a relative name which is equivalent
  555.      to FILENAME when interpreted relative to DIRECTORY.  (If such a
  556.      relative name would be longer than the absolute name, it returns
  557.      the absolute name instead.)
  558.    * The function `file-newest-backup' returns the name of the most
  559.      recent backup file for FILENAME, or `nil' that file has no backup
  560.      files.
  561.    * The list returned by `file-attributes' now has 12 elements.  The
  562.      12th element is the file system number of the file system that the
  563.      file is in.  This element together with the file's inode number,
  564.      which is the 11th element, give enough information to distinguish
  565.      any two files on the system--no two files can have the same values
  566.      for both of these numbers.
  567.    * The new function `set-visited-file-modtime' updates the current
  568.      buffer's recorded modification time from the visited file's time.
  569.      This is useful if the buffer was not read from the file normally,
  570.      or if the file itself has been changed for some known benign
  571.      reason.
  572.      If you give the function an argument, that argument specifies the
  573.      new value for the recorded modification time.  The argument should
  574.      be a list of the form `(HIGH . LOW)' or `(HIGH LOW)' containing
  575.      two integers, each of which holds 16 bits of the time.  (This is
  576.      the same format that `file-attributes' uses to return time values.)
  577.      The new function `visited-file-modtime' returns the recorded last
  578.      modification time, in that same format.
  579.    * The function `directory-files' now takes an optional fourth
  580.      argument which, if non-`nil', inhibits sorting the file names.
  581.      Use this if you want the utmost possible speed and don't care what
  582.      order the files are processed in.
  583.      If the order of processing is at all visible to the user, then the
  584.      user will probably be happier if you do sort the names.
  585.    * The variable `directory-abbrev-alist' contains an alist of
  586.      abbreviations to use for file directories.  Each element has the
  587.      form `(FROM . TO)', and says to replace FROM with TO when it
  588.      appears in a directory name.  This replacement is done when
  589.      setting up the default directory of a newly visited file.  The
  590.      FROM string is actually a regular expression; it should always
  591.      start with `^'.
  592.      You can set this variable in `site-init.el' to describe the
  593.      abbreviations appropriate for your site.
  594.    * The function `abbreviate-file-name' applies abbreviations from
  595.      `directory-abbrev-alist' to its argument, and substitutes `~' for
  596.      the user's home directory.
  597.      Abbreviated directory names are useful for directories that are
  598.      normally accessed through symbolic links.  If you think of the
  599.      link's name as "the name" of the directory, you can define it as
  600.      an abbreviation for the directory's official name; then ordinarily
  601.      Emacs will call that directory by the link name you normally use.
  602.    * `write-region' can write a given string instead of text from the
  603.      buffer.  Use the string as the first argument (in place of the
  604.      starting character position).
  605.      You can supply a second file name as the fifth argument (VISIT).
  606.      Use this to write the data to one file (the first argument,
  607.      FILENAME) while nominally visiting a different file (the fifth
  608.      argument, VISIT).  The argument VISIT is used in the echo area
  609.      message and also for file locking; VISIT is stored in
  610.      `buffer-file-name'.
  611.    * The value of `write-file-hooks' does not change when you switch to
  612.      a new major mode.  The intention is that these hooks have to do
  613.      with where the file came from, and not with what it contains.
  614.    * There is a new hook variable for saving files:
  615.      `write-contents-hooks'.  It works just like `write-file-hooks'
  616.      except that switching to a new major mode clears it back to `nil'.
  617.      Major modes should use this hook variable rather than
  618.      `write-file-hooks'.
  619.    * The hook `after-save-hook' runs just after a buffer has been saved
  620.      in its visited file.
  621.    * The new function `set-default-file-modes' sets the file protection
  622.      for new files created with Emacs.  The argument must be an
  623.      integer.  (It would be better to permit symbolic arguments like
  624.      the `chmod' program, but that would take more work than this
  625.      function merits.)
  626.      Use the new function `default-file-modes' to read the current
  627.      default file mode.
  628.    * Call the new function `unix-sync' to force all pending disk output
  629.      to happen as soon as possible.
  630. Making Certain File Names "Magic"
  631. =================================
  632.    You can implement special handling for a class of file names.  You
  633. must supply a regular expression to define the class of names (all those
  634. which match the regular expression), plus a handler that implements all
  635. the primitive Emacs file operations for file names that do match.
  636.    The value of `file-name-handler-alist' is a list of handlers,
  637. together with regular expressions that decide when to apply each
  638. handler.  Each element has the form `(REGEXP . HANDLER)'.  If a file
  639. name matches REGEXP, then all work on that file is done by calling
  640. HANDLER.
  641.    All the Emacs primitives for file access and file name transformation
  642. check the given file name against `file-name-handler-alist', and call
  643. HANDLER to do the work if appropriate.  The first argument given to
  644. HANDLER is the name of the primitive; the remaining arguments are the
  645. arguments that were passed to that primitive.  (The first of these
  646. arguments is typically the file name itself.)  For example, if you do
  647. this:
  648.      (file-exists-p FILENAME)
  649. and FILENAME has handler HANDLER, then HANDLER is called like this:
  650.      (funcall HANDLER 'file-exists-p FILENAME)
  651.    Here are the primitives that you can handle in this way:
  652.      `add-name-to-file', `copy-file', `delete-directory',
  653.      `delete-file', `directory-file-name', `directory-files',
  654.      `dired-compress-file', `dired-uncache', `expand-file-name',
  655.      `file-accessible-directory-p', `file-attributes',
  656.      `file-directory-p', `file-executable-p', `file-exists-p',
  657.      `file-local-copy', `file-modes', `file-name-all-completions',
  658.      `file-name-as-directory', `file-name-completion',
  659.      `file-name-directory', `file-name-nondirectory',
  660.      `file-name-sans-versions', `file-newer-than-file-p',
  661.      `file-readable-p', `file-symlink-p', `file-writable-p',
  662.      `insert-directory', `insert-file-contents', `load',
  663.      `make-directory', `make-symbolic-link', `rename-file',
  664.      `set-file-modes', `set-visited-file-modtime',
  665.      `unhandled-file-name-directory', `verify-visited-file-modtime',
  666.      `write-region'.
  667.    The handler function must handle all of the above operations, and
  668. possibly others to be added in the future.  Therefore, it should always
  669. reinvoke the ordinary Lisp primitive when it receives an operation it
  670. does not recognize.  Here's one way to do this:
  671.      (defun my-file-handler (operation &rest args)
  672.        ;; First check for the specific operations
  673.        ;; that we have special handling for.
  674.        (cond ((eq operation 'insert-file-contents) ...)
  675.              ((eq operation 'write-region) ...)
  676.              ...
  677.              ;; Handle any operation we don't know about.
  678.              (t (let (file-name-handler-alist)
  679.                   (apply operation args)))))
  680.    The function `file-local-copy' copies file FILENAME to the local
  681. site, if it isn't there already.  If FILENAME specifies a "magic" file
  682. name which programs outside Emacs cannot directly read or write, this
  683. copies the contents to an ordinary file and returns that file's name.
  684.    If FILENAME is an ordinary file name, not magic, then this function
  685. does nothing and returns `nil'.
  686.    The function `unhandled-file-name-directory' is used to get a
  687. non-magic directory name from an arbitrary file name.  It uses the
  688. directory part of the specified file name if that is not magic.
  689. Otherwise, it asks the file name's handler what to do.
  690. Frames
  691. ======
  692.    Emacs now supports multiple X windows via a new data type known as a
  693. "frame".
  694.    A frame is a rectangle on the screen that contains one or more Emacs
  695. windows.  Subdividing a frame works just like subdividing the screen in
  696. earlier versions of Emacs.
  697.    There are two kinds of frames: terminal frames and X window frames.
  698. Emacs creates one terminal frame when it starts up with no X display; it
  699. uses Termcap or Terminfo to display using characters.  There is no way
  700. to create another terminal frame after startup.  If Emacs has an X
  701. display, it does not make a terminal frame, and there is none.
  702.    When you are using X windows, Emacs starts out with a single X window
  703. frame.  You can create any number of X window frames using `make-frame'.
  704.    Use the predicate `framep' to determine whether a given Lisp object
  705. is a frame.
  706.    The function `redraw-frame' redisplays the entire contents of a
  707. given frame.
  708. Creating and Deleting Frames
  709. ----------------------------
  710.    Use `make-frame' to create a new frame.  This is the only primitive
  711. for creating frames.  In principle it could work under any window system
  712. which Emacs understands; the only one we support is X.
  713.    `make-frame' takes just one argument, which is an alist specifying
  714. frame parameters.  Any parameters not mentioned in the argument alist
  715. default based on the value of `default-frame-alist'; parameters not
  716. specified there default from the standard X defaults file and X
  717. resources.
  718.    When you invoke Emacs, if you specify arguments for window appearance
  719. and so forth, these go into `default-frame-alist' and that is how they
  720. have their effect.
  721.    You can specify the parameters for the initial startup X window
  722. frame by setting `initial-frame-alist' in your `.emacs' file.  If these
  723. parameters specify a separate minibuffer-only frame, and you have not
  724. created one, Emacs creates one for you, using the parameter values
  725. specified in `minibuffer-frame-alist'.
  726.    You can specify the size and position of a frame using the frame
  727. parameters `left', `top', `height' and `width'.  You must specify
  728. either both size parameters or neither.  You must specify either both
  729. position parameters or neither.  The geometry parameters that you don't
  730. specify are chosen by the window manager in its usual fashion.
  731.    The function `x-parse-geometry' converts a standard X-style geometry
  732. string to an alist which you can use as part of the argument to
  733. `make-frame'.
  734.    Use the function `delete-frame' to eliminate a frame.  Frames are
  735. like buffers where deletion is concerned; a frame actually continues to
  736. exist as a Lisp object until it is deleted *and* there are no
  737. references to it, but once it is deleted, it has no further effect on
  738. the screen.
  739.    The function `frame-live-p' returns non-`nil' if the argument (a
  740. frame) has not been deleted.
  741. Finding All Frames
  742. ------------------
  743.    The function `frame-list' returns a list of all the frames that have
  744. not been deleted.  It is analogous to `buffer-list'.  The list that you
  745. get is newly created, so modifying the list doesn't have any effect on
  746. the internals of Emacs.  The function `visible-frame-list' returns the
  747. list of just the frames that are visible.
  748.    `next-frame' lets you cycle conveniently through all the frames from
  749. an arbitrary starting point.  Its first argument is a frame.  Its second
  750. argument MINIBUF says what to do about minibuffers:
  751. `nil'
  752.      Exclude minibuffer-only frames.
  753. a window
  754.      Consider only the frames using that particular window as their
  755.      minibuffer.
  756. anything else
  757.      Consider all frames.
  758. Frames and Windows
  759. ------------------
  760.    All the non-minibuffer windows in a frame are arranged in a tree of
  761. subdivisions; the root of this tree is available via the function
  762. `frame-root-window'.  Each window is part of one and only one frame;
  763. you can get the frame with `window-frame'.
  764.    At any time, exactly one window on any frame is "selected within the
  765. frame".  You can get the frame's current selected window with
  766. `frame-selected-window'.  The significance of this designation is that
  767. selecting the frame selects for Emacs as a whole the window currently
  768. selected within that frame.
  769.    Conversely, selecting a window for Emacs with `select-window' also
  770. makes that window selected within its frame.
  771. Frame Visibility
  772. ----------------
  773.    A frame may be "visible", "invisible", or "iconified".  If it is
  774. invisible, it doesn't show in the screen, not even as an icon.  You can
  775. set the visibility status of a frame with `make-frame-visible',
  776. `make-frame-invisible', and `iconify-frame'.  You can examine the
  777. visibility status with `frame-visible-p'--it returns `t' for a visible
  778. frame, `nil' for an invisible frame, and `icon' for an iconified frame.
  779. Selected Frame
  780. --------------
  781.    At any time, one frame in Emacs is the "selected frame".  The
  782. selected window always resides on the selected frame.
  783.  - Function: selected-frame
  784.      This function returns the selected frame.
  785.    The X server normally directs keyboard input to the X window that the
  786. mouse is in.  Some window managers use mouse clicks or keyboard events
  787. to "shift the focus" to various X windows, overriding the normal
  788. behavior of the server.
  789.    Lisp programs can switch frames "temporarily" by calling the function
  790. `select-frame'.  This does not override the window manager; rather, it
  791. escapes from the window manager's control until that control is somehow
  792. reasserted.  The function takes one argument, a frame, and selects that
  793. frame.  The selection lasts until the next time the user does something
  794. to select a different frame, or until the next time this function is
  795. called.
  796.    Emacs cooperates with the X server and the window managers by
  797. arranging to select frames according to what the server and window
  798. manager ask for.  It does so by generating a special kind of input
  799. event, called a "focus" event.  The command loop handles a focus event
  800. by calling `internal-select-frame'.
  801. Frame Size and Position
  802. -----------------------
  803.    The new functions `frame-height' and `frame-width' return the height
  804. and width of a specified frame (or of the selected frame), measured in
  805. characters.
  806.    The new functions `frame-pixel-height' and `frame-pixel-width'
  807. return the height and width of a specified frame (or of the selected
  808. frame), measured in pixels.
  809.    The new functions `frame-char-height' and `frame-char-width' return
  810. the height and width of a character in a specified frame (or in the
  811. selected frame), measured in pixels.
  812.    `set-frame-size' sets the size of a frame, measured in characters;
  813. its arguments are FRAME, COLS and ROWS.  To set the size with values
  814. measured in pixels, you can use `modify-frame-parameters'.
  815.    The function `set-frame-position' sets the position of the top left
  816. corner of a frame.  Its arguments are FRAME, LEFT and TOP.
  817. Frame Parameters
  818. ----------------
  819.    A frame has many parameters that affect how it displays.  Use the
  820. function `frame-parameters' to get an alist of all the parameters of a
  821. given frame.  To alter parameters, use `modify-frame-parameters', which
  822. takes two arguments: the frame to modify, and an alist of parameters to
  823. change and their new values.  Each element of ALIST has the form `(PARM
  824. . VALUE)', where PARM is a symbol.  Parameters that aren't meaningful
  825. are ignored.  If you don't mention a parameter in ALIST, its value
  826. doesn't change.
  827.    Just what parameters a frame has depends on what display mechanism it
  828. uses.  Here is a table of the parameters of an X window frame:
  829. `name'
  830.      The name of the frame.
  831. `left'
  832.      The screen position of the left edge.
  833. `top'
  834.      The screen position of the top edge.
  835. `height'
  836.      The height of the frame contents, in pixels.
  837. `width'
  838.      The width of the frame contents, in pixels.
  839. `window-id'
  840.      The number of the X window for the frame.
  841. `minibuffer'
  842.      Whether this frame has its own minibuffer.  `t' means yes, `none'
  843.      means no, `only' means this frame is just a minibuffer, a
  844.      minibuffer window (in some other frame) means the new frame uses
  845.      that minibuffer.
  846. `font'
  847.      The name of the font for the text.
  848. `foreground-color'
  849.      The color to use for the inside of a character.  Use strings to
  850.      designate colors; the X server defines the meaningful color names.
  851. `background-color'
  852.      The color to use for the background of text.
  853. `mouse-color'
  854.      The color for the mouse cursor.
  855. `cursor-color'
  856.      The color for the cursor that shows point.
  857. `border-color'
  858.      The color for the border of the frame.
  859. `cursor-type'
  860.      The way to display the cursor.  There are two legitimate values:
  861.      `bar' and `box'.  The value `bar' specifies a vertical bar between
  862.      characters as the cursor.  The value `box' specifies an ordinary
  863.      black box overlaying the character after point; that is the
  864.      default.
  865. `icon-type'
  866.      Non-`nil' for a bitmap icon, `nil' for a text icon.
  867. `border-width'
  868.      The width in pixels of the window border.
  869. `internal-border-width'
  870.      The distance in pixels between text and border.
  871. `auto-raise'
  872.      Non-`nil' means selecting the frame raises it.
  873. `auto-lower'
  874.      Non-`nil' means deselecting the frame lowers it.
  875. `vertical-scroll-bars'
  876.      Non-`nil' gives the frame a scroll bar for vertical scrolling.
  877. Minibufferless Frames
  878. ---------------------
  879.    Normally, each frame has its own minibuffer window at the bottom,
  880. which is used whenever that frame is selected.  However, you can also
  881. create frames with no minibuffers.  These frames must use the
  882. minibuffer window of some other frame.
  883.    The variable `default-minibuffer-frame' specifies where to find a
  884. minibuffer for frames created without minibuffers of their own.  Its
  885. value should be a frame which does have a minibuffer.
  886.    You can also specify a minibuffer window explicitly when you create a
  887. frame; then `default-minibuffer-frame' is not used.
  888. X Window System Features
  889. ========================
  890.    * The new functions `mouse-position' and `set-mouse-position' give
  891.      access to the current position of the mouse.
  892.      `mouse-position' returns a description of the position of the
  893.      mouse.  The value looks like `(FRAME X . Y)', where X and Y are
  894.      measured in pixels relative to the top left corner of the inside
  895.      of FRAME.
  896.      `set-mouse-position' takes three arguments, FRAME, X and Y, and
  897.      warps the mouse cursor to that location on the screen.
  898.    * `track-mouse' is a new special form for tracking mouse motion.
  899.      Use it in definitions of mouse clicks that want pay to attention to
  900.      the motion of the mouse, not just where the buttons are pressed and
  901.      released.  Here is how to use it:
  902.           (track-mouse BODY...)
  903.      While BODY executes, mouse motion generates input events just as
  904.      mouse clicks do.  BODY can read them with `read-event' or
  905.      `read-key-sequence'.
  906.      `track-mouse' returns the value of the last form in BODY.
  907.      The format of these events is described under "New Input Event
  908.      Formats."
  909.    * `x-set-selection' sets a "selection" in the X server.  It takes
  910.      two arguments: a selection type TYPE, and the value to assign to
  911.      it, DATA.  If DATA is `nil', it means to clear out the selection.
  912.      Otherwise, DATA may be a string, a symbol, an integer (or a cons
  913.      of two integers or list of two integers), or a cons of two markers
  914.      pointing to the same buffer.  In the last case, the selection is
  915.      considered to be the text between the markers.  The data may also
  916.      be a vector of valid non-vector selection values.
  917.      Each possible TYPE has its own selection value, which changes
  918.      independently.  The usual values of TYPE are `PRIMARY' and
  919.      `SECONDARY'; these are symbols with upper-case names, in accord
  920.      with X protocol conventions.  The default is `PRIMARY'.
  921.      To get the value of the selection, call `x-get-selection'.  This
  922.      function accesses selections set up by Emacs and those set up by
  923.      other X clients.  It takes two optional arguments, TYPE and
  924.      DATA-TYPE.  The default for TYPE is `PRIMARY'.
  925.      The DATA-TYPE argument specifies the form of data conversion to
  926.      use; meaningful values include `TEXT', `STRING', `TARGETS',
  927.      `LENGTH', `DELETE', `FILE_NAME', `CHARACTER_POSITION',
  928.      `LINE_NUMBER', `COLUMN_NUMBER', `OWNER_OS', `HOST_NAME', `USER',
  929.      `CLASS', `NAME', `ATOM', and `INTEGER'.  (These are symbols with
  930.      upper-case names in accord with X Windows conventions.) The
  931.      default for DATA-TYPE is `STRING'.
  932.    * The X server has a set of numbered "cut buffers" which can store
  933.      text or other data being moved between applications.  Use
  934.      `x-get-cut-buffer' to get the contents of a cut buffer; specify the
  935.      cut buffer number as argument.  Use `x-set-cut-buffer' with
  936.      argument STRING to store a new string into the first cut buffer
  937.      (moving the other values down through the series of cut buffers,
  938.      kill-ring-style).
  939.      Cut buffers are considered obsolete, but Emacs supports them for
  940.      the sake of X clients that still use them.
  941.    * You can close the connection with the X server with the function
  942.      `x-close-current-connection'.  This takes no arguments.
  943.      Then you can connect to a different X server with
  944.      `x-open-connection'.  The first argument, DISPLAY, is the name of
  945.      the display to connect to.
  946.      The optional second argument XRM-STRING is a string of resource
  947.      names and values, in the same format used in the `.Xresources'
  948.      file.  The values you specify override the resource values
  949.      recorded in the X server itself.  Here's an example of what this
  950.      string might look like:
  951.           "*BorderWidth: 3\n*InternalBorder: 2\n"
  952.    * A series of new functions give you information about the X server
  953.      and the screen you are using.
  954.     `x-display-screens'
  955.           The number of screens associated with the current display.
  956.     `x-server-version'
  957.           The version numbers of the X server in use.
  958.     `x-server-vendor'
  959.           The vendor supporting the X server in use.
  960.     `x-display-pixel-height'
  961.           The height of this X screen in pixels.
  962.     `x-display-mm-height'
  963.           The height of this X screen in millimeters.
  964.     `x-display-pixel-width'
  965.           The width of this X screen in pixels.
  966.     `x-display-mm-width'
  967.           The width of this X screen in millimeters.
  968.     `x-display-backing-store'
  969.           The backing store capability of this screen.  Values can be
  970.           the symbols `always', `when-mapped', or `not-useful'.
  971.     `x-display-save-under'
  972.           Non-`nil' if this X screen supports the SaveUnder feature.
  973.     `x-display-planes'
  974.           The number of planes this display supports.
  975.     `x-display-visual-class'
  976.           The visual class for this X screen.  The value is one of the
  977.           symbols `static-gray', `gray-scale', `static-color',
  978.           `pseudo-color', `true-color', and `direct-color'.
  979.     `x-display-color-p'
  980.           `t' if the X screen in use is a color screen.
  981.     `x-display-color-cells'
  982.           The number of color cells this X screen supports.
  983.      There is also a variable `x-no-window-manager', whose value is `t'
  984.      if no X window manager is in use.
  985.    * The function `x-synchronize' enables or disables an X Windows
  986.      debugging mode: synchronous communication.  It takes one argument,
  987.      non-`nil' to enable the mode and `nil' to disable.
  988.      In synchronous mode, Emacs waits for a response to each X protocol
  989.      command before doing anything else.  This means that errors are
  990.      reported right away, and you can directly find the erroneous
  991.      command.  Synchronous mode is not the default because it is much
  992.      slower.
  993.    * The function `x-get-resource' retrieves a resource value from the X
  994.      Windows defaults database.  Its three arguments are ATTRIBUTE,
  995.      NAME and CLASS.  It searches using a key of the form
  996.      `INSTANCE.ATTRIBUTE', with class `Emacs', where INSTANCE is the
  997.      name under which Emacs was invoked.
  998.      The optional arguments COMPONENT and SUBCLASS add to the key and
  999.      the class, respectively.  You must specify both of them or neither.
  1000.      If you specify them, the key is `INSTANCE.COMPONENT.ATTRIBUTE',
  1001.      and the class is `Emacs.SUBCLASS'.
  1002.    * `x-display-color-p' returns `t' if you are using an X server with
  1003.      a color display, and `nil' otherwise.
  1004.      `x-color-defined-p' takes as argument a string describing a color;
  1005.      it returns `t' if the display supports that color.  (If the color
  1006.      is `"black"' or `"white"' then even black-and-white displays
  1007.      support it.)
  1008.    * `x-popup-menu' has been generalized.  It now accepts a keymap as
  1009.      the MENU argument.  Then the menu items are the prompt strings of
  1010.      individual key bindings, and the item values are the keys which
  1011.      have those bindings.
  1012.      You can also supply a list of keymaps as the first argument; then
  1013.      each keymap makes one menu pane (but keymaps that don't provide
  1014.      any menu items don't appear in the menu at all).
  1015.      `x-popup-menu' also accepts a mouse button event as the POSITION
  1016.      argument.  Then it displays the menu at the location at which the
  1017.      event took place.  This is convenient for mouse-invoked commands
  1018.      that pop up menus.
  1019.    * You can use the function `x-rebind-key' to change the sequence of
  1020.      characters generated by the X server for one of the keyboard keys.
  1021.      The first two arguments, KEYCODE and SHIFT-MASK, should be numbers
  1022.      representing the keyboard code and shift mask respectively.  They
  1023.      specify what key to change.
  1024.      The third argument, NEWSTRING, is the new definition of the key.
  1025.      It is a sequence of characters that the key should produce as
  1026.      input.
  1027.      The shift mask value is a combination of bits according to this
  1028.      table:
  1029.     8
  1030.           Control
  1031.     4
  1032.           Meta
  1033.     2
  1034.           Shift
  1035.     1
  1036.           Shift Lock
  1037.      If you specify `nil' for SHIFT-MASK, then the key specified by
  1038.      KEYCODE is redefined for all possible shift combinations.
  1039.      For the possible values of KEYCODE and their meanings, see the
  1040.      file `/usr/lib/Xkeymap.txt'.  Keep in mind that the codes in that
  1041.      file are in octal!
  1042.      The related function `x-rebind-keys' redefines a single keyboard
  1043.      key, specifying the behavior for each of the 16 shift masks
  1044.      independently.  The first argument is KEYCODE, as in
  1045.      `x-rebind-key'.  The second argument STRINGS is a list of 16
  1046.      elements, one for each possible shift mask value; each element
  1047.      says how to redefine the key KEYCODE with the corresponding shift
  1048.      mask value.  If an element is a string, it is the new definition.
  1049.      If an element is `nil', the definition does not change for that
  1050.      shift mask.
  1051.    * The function `x-parse-geometry' parses a string specifying window
  1052.      size and position in the usual X format.  It returns an alist
  1053.      describing which parameters were specified, and the values that
  1054.      were given for them.
  1055.      The elements of the alist look like `(PARAMETER .  VALUE)'.  The
  1056.      possible PARAMETER values are `left', `top', `width', and `height'.
  1057. New Window Features
  1058. ===================
  1059.    * The new function `window-at' tells you which window contains a
  1060.      given horizontal and vertical position on a specified frame.  Call
  1061.      it with three arguments, like this:
  1062.           (window-at X COLUMN FRAME)
  1063.      The function returns the window which contains that cursor
  1064.      position in the frame FRAME.  If you omit FRAME, the selected
  1065.      frame is used.
  1066.    * The function `coordinates-in-window-p' takes two arguments and
  1067.      checks whether a particular frame position falls within a
  1068.      particular window.
  1069.           (coordinates-in-window-p COORDINATES WINDOW)
  1070.      The argument COORDINATES is a cons cell of this form:
  1071.           (X . Y)
  1072.      The two coordinates are measured in characters, and count from the
  1073.      top left corner of the screen or frame.
  1074.      The value of the function tells you what part of the window the
  1075.      position is in.  The possible values are:
  1076.     `(RELX . RELY)'
  1077.           The coordinates are inside WINDOW.  The numbers RELX and RELY
  1078.           are equivalent window-relative coordinates, counting from 0
  1079.           at the top left corner of the window.
  1080.     `mode-line'
  1081.           The coordinates are in the mode line of WINDOW.
  1082.     `vertical-split'
  1083.           The coordinates are in the vertical line between WINDOW and
  1084.           its neighbor to the right.
  1085.     `nil'
  1086.           The coordinates are not in any sense within WINDOW.
  1087.      You need not specify a frame when you call
  1088.      `coordinates-in-window-p', because it assumes you mean the frame
  1089.      which window WINDOW is on.
  1090.    * The function `minibuffer-window' now accepts a frame as argument
  1091.      and returns the minibuffer window used for that frame.  If you
  1092.      don't specify a frame, the currently selected frame is used.  The
  1093.      minibuffer window may be on the frame in question, but if that
  1094.      frame has no minibuffer of its own, it uses the minibuffer window
  1095.      of some other frame, and `minibuffer-window' returns that window.
  1096.    * Use `window-live-p' to test whether a window is still alive (that
  1097.      is, not deleted).
  1098.    * Use `window-minibuffer-p' to determine whether a given window is a
  1099.      minibuffer or not.  It no longer works to do this by comparing the
  1100.      window with the result of `(minibuffer-window)', because there can
  1101.      be more than one minibuffer window at a time (if you have multiple
  1102.      frames).
  1103.    * If you set the variable `pop-up-frames' non-`nil', then the
  1104.      functions to show something "in another window" actually create a
  1105.      new frame for the new window.  Thus, you will tend to have a frame
  1106.      for each window, and you can easily have a frame for each buffer.
  1107.      The value of the variable `pop-up-frame-function' controls how new
  1108.      frames are made.  The value should be a function which takes no
  1109.      arguments and returns a frame.  The default value is a function
  1110.      which creates a frame using parameters from `pop-up-frame-alist'.
  1111.    * `display-buffer' is the basic primitive for finding a way to show a
  1112.      buffer on the screen.  You can customize its behavior by storing a
  1113.      function in the variable `display-buffer-function'.  If this
  1114.      variable is non-`nil', then `display-buffer' calls it to do the
  1115.      work.  Your function should accept two arguments, as follows:
  1116.     BUFFER
  1117.           The buffer to be displayed.
  1118.     FLAG
  1119.           A flag which, if non-`nil', means you should find another
  1120.           window to display BUFFER in, even if it is already visible in
  1121.           the selected window.
  1122.      The function you supply will be used by commands such as
  1123.      `switch-to-buffer-other-window' and `find-file-other-window' as
  1124.      well as for your own calls to `display-buffer'.
  1125.    * `delete-window' now gives all of the deleted window's screen space
  1126.      to a single neighboring window.  Likewise, `enlarge-window' takes
  1127.      space from only one neighboring window until that window
  1128.      disappears; only then does it take from another window.
  1129.    * `next-window' and `previous-window' accept another argument,
  1130.      ALL-FRAMES.
  1131.      These functions now take three optional arguments: WINDOW, MINIBUF
  1132.      and ALL-FRAMES.  WINDOW is the window to start from (`nil' means
  1133.      use the selected window).  MINIBUF says whether to include the
  1134.      minibuffer in the windows to cycle through: `t' means yes, `nil'
  1135.      means yes if it is active, and anything else means no.
  1136.      Normally, these functions cycle through all the windows in the
  1137.      selected frame, plus the minibuffer used by the selected frame
  1138.      even if it lies in some other frame.
  1139.      If ALL-FRAMES is `t', then these functions cycle through all the
  1140.      windows in all the frames that currently exist.  If ALL-FRAMES is
  1141.      neither `t' nor `nil', then they limit themselves strictly to the
  1142.      windows in the selected frame, excluding the minibuffer in use if
  1143.      it lies in some other frame.
  1144.    * The functions `get-lru-window' and `get-largest-window' now take
  1145.      an optional argument ALL-FRAMES.  If it is non-`nil', the
  1146.      functions consider all windows on all frames.  Otherwise, they
  1147.      consider just the windows on the selected frame.
  1148.      Likewise, `get-buffer-window' takes an optional second argument
  1149.      ALL-FRAMES.
  1150.    * The variable `other-window-scroll-buffer' specifies which buffer
  1151.      `scroll-other-window' should scroll.
  1152.    * You can now mark a window as "dedicated" to its buffer.  Then
  1153.      Emacs will not try to use that window for any other buffer unless
  1154.      you explicitly request it.
  1155.      Use the new function `set-window-dedicated-p' to set the dedication
  1156.      flag of a window WINDOW to the value FLAG.  If FLAG is `t', this
  1157.      makes the window dedicated.  If FLAG is `nil', this makes the
  1158.      window non-dedicated.
  1159.      Use `window-dedicated-p' to examine the dedication flag of a
  1160.      specified window.
  1161.    * The new function `walk-windows' cycles through all visible
  1162.      windows, calling `proc' once for each window with the window as
  1163.      its sole argument.
  1164.      The optional second argument MINIBUF says whether to include
  1165.      minibuffer windows.  A value of `t' means count the minibuffer
  1166.      window even if not active.  A value of `nil' means count it only
  1167.      if active.  Any other value means not to count the minibuffer even
  1168.      if it is active.
  1169.      If the optional third argument ALL-FRAMES is `t', that means
  1170.      include all windows in all frames.  If ALL-FRAMES is `nil', it
  1171.      means to cycle within the selected frame, but include the
  1172.      minibuffer window (if MINIBUF says so) that that frame uses, even
  1173.      if it is on another frame.  If ALL-FRAMES is neither `nil' nor `t',
  1174.      `walk-windows' sticks strictly to the selected frame.
  1175.    * The function `window-end' is a counterpart to `window-start': it
  1176.      returns the buffer position of the end of the display in a given
  1177.      window (or the selected window).
  1178.    * The function `window-configuration-p' returns non-`nil' when given
  1179.      an object that is a window configuration (such as is returned by
  1180.      `current-window-configuration').
  1181. Display Features
  1182. ================
  1183.    * `baud-rate' is now a variable rather than a function.  This is so
  1184.      you can set it to reflect the effective speed of your terminal,
  1185.      when the system doesn't accurately know the speed.
  1186.    * You can now remove any echo area message and make the minibuffer
  1187.      visible.  To do this, call `message' with `nil' as the only
  1188.      argument.  This clears any existing message, and lets the current
  1189.      minibuffer contents show through.  Previously, there was no
  1190.      reliable way to make sure that the minibuffer contents were
  1191.      visible.
  1192.    * The variable `temp-buffer-show-hook' has been renamed
  1193.      `temp-buffer-show-function', because its value is a single function
  1194.      (of one argument), not a normal hook.
  1195.    * The new function `force-mode-line-update' causes redisplay of the
  1196.      current buffer's mode line.
  1197. Display Tables
  1198. ==============
  1199.    You can use the "display table" feature to control how all 256
  1200. possible character codes display on the screen.  This is useful for
  1201. displaying European languages that have letters not in the ASCII
  1202. character set.
  1203.    The display table maps each character code into a sequence of
  1204. "glyphs", each glyph being an image that takes up one character
  1205. position on the screen.  You can also define how to display each glyph
  1206. on your terminal, using the "glyph table".
  1207. Display Tables Proper
  1208. ---------------------
  1209.    Use `make-display-table' to create a display table.  The table
  1210. initially has `nil' in all elements.
  1211.    A display table is actually an array of 261 elements.  The first 256
  1212. elements of a display table control how to display each possible text
  1213. character.  The value should be `nil' or a vector (which is a sequence
  1214. of glyphs; see below).  `nil' as an element means to display that
  1215. character following the usual display conventions.
  1216.    The remaining five elements of a display table serve special purposes
  1217. (`nil' means use the default stated below):
  1218.      The glyph for the end of a truncated screen line (the default for
  1219.      this is `\').
  1220.      The glyph for the end of a continued line (the default is `$').
  1221.      The glyph for the indicating an octal character code (the default
  1222.      is `\').
  1223.      The glyph for indicating a control characters (the default is `^').
  1224.      The vector of glyphs for indicating the presence of invisible
  1225.      lines (the default is `...').
  1226.    Each buffer typically has its own display table.  The display table
  1227. for the current buffer is stored in `buffer-display-table'.  (This
  1228. variable automatically becomes local if you set it.)  If this variable
  1229. is `nil', the value of `standard-display-table' is used in that buffer.
  1230.    Each window can have its own display table, which overrides the
  1231. display table of the buffer it is showing.
  1232.    If neither the selected window nor the current buffer has a display
  1233. table, and if `standard-display-table' is `nil', then Emacs uses the
  1234. usual display conventions:
  1235.    * Character codes 32 through 127 map to glyph codes 32 through 127.
  1236.    * Codes 0 through 31 map to sequences of two glyphs, where the first
  1237.      glyph is the ASCII code for `^'.
  1238.    * Character codes 128 through 255 map to sequences of four glyphs,
  1239.      where the first glyph is the ASCII code for `\', and the others
  1240.      represent digits.
  1241.    The usual display conventions are also used for any character whose
  1242. entry in the active display table is `nil'.  This means that when you
  1243. set up a display table, you need not specify explicitly what to do with
  1244. each character, only the characters for which you want unusual behavior.
  1245. Glyphs
  1246. ------
  1247.    A glyph stands for an image that takes up a single character
  1248. position on the screen.  A glyph is represented in Lisp as an integer.
  1249.    The meaning of each integer, as a glyph, is defined by the glyph
  1250. table, which is the value of the variable `glyph-table'.  It should be a
  1251. vector; the Gth element defines glyph code G.  The possible definitions
  1252. of a glyph code are:
  1253. INTEGER
  1254.      Define this glyph code as an alias for code INTEGER.  This is used
  1255.      with X Windows to specify a face code.
  1256. STRING
  1257.      Send the characters in STRING to the terminal to output this
  1258.      glyph.  This alternative is available only for character
  1259.      terminals, not with X.
  1260. `NIL'
  1261.      This glyph is simple.  On an ordinary terminal, the glyph code mod
  1262.      256 is the character to output.  With X, the glyph code mod 256 is
  1263.      character to output, and the glyph code divided by 256 specifies
  1264.      the "face code" to use while outputting it.
  1265.    Any glyph code beyond the length of the glyph table is automatically
  1266. simple.
  1267.    If `glyph-table' is `nil', then all possible glyph codes are simple.
  1268.    A "face" is a named combination of a font and a pair of colors
  1269. (foreground and background).  A glyph code can specify a face id number
  1270. to use for displaying that glyph.
  1271. ISO Latin 1
  1272. -----------
  1273.    If you have a terminal that can handle the entire ISO Latin 1
  1274. character set, you can arrange to use that character set as follows:
  1275.      (require 'disp-table)
  1276.      (standard-display-8bit 0 255)
  1277.    If you are editing buffers written in the ISO Latin 1 character set
  1278. and your terminal doesn't handle anything but ASCII, you can load the
  1279. file `iso-ascii' to set up a display table which makes the other ISO
  1280. characters display as sequences of ASCII characters.  For example, the
  1281. character "o with umlaut" displays as `{"o}'.
  1282.    Some European countries have terminals that don't support ISO Latin 1
  1283. but do support the special characters for that country's language.  You
  1284. can define a display table to work one language using such terminals.
  1285. For an example, see `lisp/iso-swed.el', which handles certain Swedish
  1286. terminals.
  1287.    You can load the appropriate display table for your terminal
  1288. automatically by writing a terminal-specific Lisp file for the terminal
  1289. type.
  1290. Overlays
  1291. ========
  1292.    You can use "overlays" to alter the appearance of a buffer's text on
  1293. the screen.  An overlay is an object which belongs to a particular
  1294. buffer, and has a specified beginning and end.  It also has properties
  1295. which you can examine and set; these affect the display of the text
  1296. within the overlay.
  1297. Overlay Properties
  1298. ------------------
  1299.    Overlay properties are like text properties in some respects, but the
  1300. differences are more important than the similarities.  Text properties
  1301. are considered a part of the text; overlays are specifically considered
  1302. not to be part of the text.  Thus, copying text between various buffers
  1303. and strings preserves text properties, but does not try to preserve
  1304. overlays.  Changing a buffer's text properties marks the buffer as
  1305. modified, while moving an overlay or changing its properties does not.
  1306. `face'
  1307.      This property specifies a face for displaying the text within the
  1308.      overlay.
  1309. `priority'
  1310.      This property's value (which should be a nonnegative number)
  1311.      determines the priority of the overlay.  The priority matters when
  1312.      two or more overlays cover the same character and both specify a
  1313.      face for display; the one whose `priority' value is larger takes
  1314.      priority over the other, and its face attributes override the face
  1315.      attributes of the lower priority overlay.
  1316.      Currently, all overlays take priority over text properties.  Please
  1317.      avoid using negative priority values, as we have not yet decided
  1318.      just what they should mean.
  1319. `window'
  1320.      If the `window' property is non-`nil', then the overlay applies
  1321.      only on that window.
  1322. Overlay Functions
  1323. -----------------
  1324.    Use the functions `overlay-get' and `overlay-put' to access and set
  1325. the properties of an overlay.  They take arguments like `get' and
  1326. `put', except that the first argument is an overlay rather than a
  1327. symbol.
  1328.    To create an overlay, call `(make-overlay START END)'.  You can
  1329. specify the buffer as the third argument if you wish.  To delete one,
  1330. use `delete-overlay'.
  1331.    Use `overlay-start', `overlay-end' and `overlay-buffer' to examine
  1332. the location and range of an overlay.  Use `move-overlay' to change
  1333. them; its arguments are OVERLAY, START, END and (optionally) the buffer.
  1334.    There are two functions to search for overlays: `overlays-at' and
  1335. `next-overlay-change'.  `overlays-at' returns a list of all the
  1336. overlays containing a particular position.  `(next-overlay-change POS)'
  1337. returns the position of the next overlay beginning or end following POS.
  1338. Faces
  1339. =====
  1340.    A "face" is a named collection of graphical attributes: font,
  1341. foreground color, background color and optional underlining.  Faces
  1342. control the display of text on the screen.
  1343.    Each face has its own "face id number" which distinguishes faces at
  1344. low levels within Emacs.  However, for most purposes, you can refer to
  1345. faces in Lisp programs by their names.
  1346.    Each face name is meaningful for all frames, and by default it has
  1347. the same meaning in all frames.  But you can arrange to give a
  1348. particular face name a special meaning in one frame if you wish.
  1349. Choosing a Face for Display
  1350. ---------------------------
  1351.    Here are all the ways to specify which face to use for display of
  1352. text:
  1353.    * With defaults.  Each frame has a "default face", whose id number is
  1354.      zero, which is used for all text that doesn't somehow specify
  1355.      another face.
  1356.    * With text properties.  A character may have a `face' property; if
  1357.      so, it's displayed with that face.  If the character has a
  1358.      `mouse-face' property, that is used instead of the `face' property
  1359.      when the mouse is "near enough" to the character.
  1360.    * With overlays.  An overlay may have `face' and `mouse-face'
  1361.      properties too; they apply to all the text covered by the overlay.
  1362.    * With special glyphs.  Each glyph can specify a particular face id
  1363.      number.
  1364.    If these various sources together specify more than one face for a
  1365. particular character, Emacs merges the attributes of the various faces
  1366. specified.  The attributes of the faces of special glyphs come first;
  1367. then come attributes of faces from overlays, followed by those from text
  1368. properties, and last the default face.
  1369.    When multiple overlays cover one character, an overlay with higher
  1370. priority overrides those with lower priority.
  1371.    If an attribute such as the font or a color is not specified in any
  1372. of the above ways, the frame's own font or color is used.
  1373.    *Note Face Functions: (elisp)Face Functions, for functions to create
  1374. and change faces.
  1375. New Input Event Formats
  1376. =======================
  1377.    Mouse clicks, mouse movements and function keys no longer appear in
  1378. the input stream as characters; instead, other kinds of Lisp objects
  1379. represent them as input.
  1380.    * An ordinary input character event consists of a "basic code"
  1381.      between 0 and 255, plus any or all of these "modifier bits":
  1382.     meta
  1383.           The 2**23 bit in the character code indicates a character
  1384.           typed with the meta key held down.
  1385.     control
  1386.           The 2**22 bit in the character code indicates a non-ASCII
  1387.           control character.
  1388.           ASCII control characters such as `C-a' have special basic
  1389.           codes of their own, so Emacs needs no special bit to indicate
  1390.           them.  Thus, the code for `C-a' is just 1.
  1391.           But if you type a control combination not in ASCII, such as
  1392.           `%' with the control key, the numeric value you get is the
  1393.           code for `%' plus 2**22 (assuming the terminal supports
  1394.           non-ASCII control characters).
  1395.     shift
  1396.           The 2**21 bit in the character code indicates an ASCII control
  1397.           character typed with the shift key held down.
  1398.           For letters, the basic code indicates upper versus lower
  1399.           case; for digits and punctuation, the shift key selects an
  1400.           entirely different character with a different basic code.  In
  1401.           order to keep within the ASCII character set whenever
  1402.           possible, Emacs avoids using the 2**21 bit for those
  1403.           characters.
  1404.           However, ASCII provides no way to distinguish `C-A' from
  1405.           `C-a', so Emacs uses the 2**21 bit in `C-A' and not in `C-a'.
  1406.     hyper
  1407.           The 2**20 bit in the character code indicates a character
  1408.           typed with the hyper key held down.
  1409.     super
  1410.           The 2**19 bit in the character code indicates a character
  1411.           typed with the super key held down.
  1412.     alt
  1413.           The 2**18 bit in the character code indicates a character
  1414.           typed with the alt key held down.  (On some terminals, the
  1415.           key labeled ALT is actually the meta key.)
  1416.      In the future, Emacs may support a larger range of basic codes.
  1417.      We may also move the modifier bits to larger bit numbers.
  1418.      Therefore, you should avoid mentioning specific bit numbers in
  1419.      your program.  Instead, the way to test the modifier bits of a
  1420.      character is with the function `event-modifiers' (see below).
  1421.    * Function keys are represented as symbols.  The symbol's name is
  1422.      the function key's label.  For example, pressing a key labeled F1
  1423.      places the symbol `f1' in the input stream.
  1424.      There are a few exceptions to the symbol naming convention:
  1425.     `kp-add', `kp-decimal', `kp-divide', ...
  1426.           Keypad keys (to the right of the regular keyboard).
  1427.     `kp-0', `kp-1', ...
  1428.           Keypad keys with digits.
  1429.     `kp-f1', `kp-f2', `kp-f3', `kp-f4'
  1430.           Keypad PF keys.
  1431.     `left', `up', `right', `down'
  1432.           Cursor arrow keys
  1433.      You can use the modifier keys CTRL, META, HYPER, SUPER, ALT and
  1434.      SHIFT with function keys.  The way to represent them is with
  1435.      prefixes in the symbol name:
  1436.     `A-'
  1437.           The alt modifier.
  1438.     `C-'
  1439.           The control modifier.
  1440.     `H-'
  1441.           The hyper modifier.
  1442.     `M-'
  1443.           The meta modifier.
  1444.     `s-'
  1445.           The super modifier.
  1446.     `S-'
  1447.           The shift modifier.
  1448.      Thus, the symbol for the key F3 with META held down is `M-F3'.
  1449.      When you use more than one prefix, we recommend you write them in
  1450.      alphabetical order (though the order does not matter in arguments
  1451.      to the key-binding lookup and modification functions).
  1452.    * Mouse events are represented as lists.
  1453.      If you press a mouse button and release it at the same location,
  1454.      this generates a "click" event.  Mouse click events have this form:
  1455.           (BUTTON-SYMBOL
  1456.            (WINDOW (COLUMN . ROW)
  1457.             BUFFER-POS TIMESTAMP))
  1458.      Here is what the elements normally mean:
  1459.     BUTTON-SYMBOL
  1460.           indicates which mouse button was used.  It is one of the
  1461.           symbols `mouse-1', `mouse-2', ..., where the buttons are
  1462.           normally numbered left to right.
  1463.           You can also use prefixes `A-', `C-', `H-', `M-', `S-' and
  1464.           `s-' for modifiers alt, control, hyper, meta, shift and
  1465.           super, just as you would with function keys.
  1466.     WINDOW
  1467.           is the window in which the click occurred.
  1468.     COLUMN
  1469.     ROW
  1470.           are the column and row of the click, relative to the top left
  1471.           corner of WINDOW, which is `(0 . 0)'.
  1472.     BUFFER-POS
  1473.           is the buffer position of the character clicked on.
  1474.     TIMESTAMP
  1475.           is the time at which the event occurred, in milliseconds.
  1476.           (Since this value wraps around the entire range of Emacs Lisp
  1477.           integers in about five hours, it is useful only for relating
  1478.           the times of nearby events.)
  1479.      The meanings of BUFFER-POS, ROW and COLUMN are somewhat different
  1480.      when the event location is in a special part of the screen, such
  1481.      as the mode line or a scroll bar.
  1482.      If the position is in the window's scroll bar, then BUFFER-POS is
  1483.      the symbol `vertical-scroll-bar', and the pair `(COLUMN . ROW)' is
  1484.      replaced with a pair `(PORTION . WHOLE)', where PORTION is the
  1485.      distance of the click from the top or left end of the scroll bar,
  1486.      and WHOLE is the length of the entire scroll bar.
  1487.      If the position is on a mode line or the vertical line separating
  1488.      WINDOW from its neighbor to the right, then BUFFER-POS is the
  1489.      symbol `mode-line' or `vertical-line'.  In this case ROW and
  1490.      COLUMN do not have meaningful data.
  1491.    * Releasing a mouse button above a different character position
  1492.      generates a "drag" event, which looks like this:
  1493.           (BUTTON-SYMBOL
  1494.            (WINDOW1 (COLUMN1 . ROW1)
  1495.             BUFFER-POS1 TIMESTAMP1)
  1496.            (WINDOW2 (COLUMN2 . ROW2)
  1497.             BUFFER-POS2 TIMESTAMP2))
  1498.      The name of BUTTON-SYMBOL contains the prefix `drag-'.  The second
  1499.      and third elements of the event give the starting and ending
  1500.      position of the drag.
  1501.      The `drag-' prefix follows the modifier key prefixes such as `C-'
  1502.      and `M-'.
  1503.      If `read-key-sequence' receives a drag event which has no key
  1504.      binding, and the corresponding click event does have a binding, it
  1505.      changes the drag event into a click event at the drag's starting
  1506.      position.  This means that you don't have to distinguish between
  1507.      click and drag events unless you want to.
  1508.    * Click and drag events happen when you release a mouse button.
  1509.      Another kind of event happens when you press a button.  It looks
  1510.      just like a click event, except that the name of BUTTON-SYMBOL
  1511.      contains the prefix `down-'.  The `down-' prefix follows the
  1512.      modifier key prefixes such as `C-' and `M-'.
  1513.      The function `read-key-sequence', and the Emacs command loop,
  1514.      ignore any down events that don't have command bindings.  This
  1515.      means that you need not worry about defining down events unless
  1516.      you want them to do something.  The usual reason to define a down
  1517.      event is so that you can track mouse motion until the button is
  1518.      released.
  1519.    * For example, if the user presses and releases the left mouse
  1520.      button over the same location, Emacs generates a sequence of
  1521.      events like this:
  1522.           (down-mouse-1 (#<window 18 on NEWS> 2613 (0 . 38) -864320))
  1523.           (mouse-1      (#<window 18 on NEWS> 2613 (0 . 38) -864180))
  1524.      Or, while holding the control key down, the user might hold down
  1525.      the second mouse button, and drag the mouse from one line to the
  1526.      next.  That produces two events, as shown here:
  1527.           (C-down-mouse-2 (#<window 18 on NEWS> 3440 (0 . 27) -731219))
  1528.           (C-drag-mouse-2 (#<window 18 on NEWS> 3440 (0 . 27) -731219)
  1529.                           (#<window 18 on NEWS> 3510 (0 . 28) -729648))
  1530.      Or, while holding down the meta and shift keys, the user might
  1531.      press the second mouse button on the window's mode line, and then
  1532.      drag the mouse into another window.  That produces an event like
  1533.      this:
  1534.           (M-S-down-mouse-2 (#<window 18 on NEWS> mode-line (33 . 31) -457844))
  1535.           (M-S-drag-mouse-2 (#<window 18 on NEWS> mode-line (33 . 31) -457844)
  1536.                             (#<window 20 on carlton-sanskrit.tex> 161 (33 . 3)
  1537.                              -453816))
  1538.    * A key sequence that starts with a mouse click is read using the
  1539.      keymaps of the buffer in the window clicked on, not the current
  1540.      buffer.
  1541.      This does not imply that clicking in a window selects that window
  1542.      or its buffer.  The execution of the command begins with no change
  1543.      in the selected window or current buffer.  However, the command
  1544.      can switch windows or buffers if programmed to do so.
  1545.    * Mouse motion events are represented by lists.  During the
  1546.      execution of the body of a `track-mouse' form, moving the mouse
  1547.      generates events that look like this:
  1548.           (mouse-movement (WINDOW (COLUMN . ROW)
  1549.                            BUFFER-POS TIMESTAMP))
  1550.      The second element of the list describes the current position of
  1551.      the mouse, just as in a mouse click event.
  1552.      Outside of `track-mouse' forms, Emacs does not generate events for
  1553.      mere motion of the mouse, and these events do not appear.
  1554.    * Focus shifts between frames are represented by lists.
  1555.      When the mouse shifts temporary input focus from one frame to
  1556.      another, Emacs generates an event like this:
  1557.           (switch-frame NEW-FRAME)
  1558.      where NEW-FRAME is the frame switched to.
  1559.      In X windows, most window managers are set up so that just moving
  1560.      the mouse into a window is enough to set the focus there.  As far
  1561.      as the user is concerned, Emacs behaves consistently with this.
  1562.      However, there is no need for the Lisp program to know about the
  1563.      focus change until some other kind of input arrives.  So Emacs
  1564.      generates the focus event only when the user actually types a
  1565.      keyboard key or presses a mouse button in the new frame; just
  1566.      moving the mouse between frames does not generate a focus event.
  1567.      The global key map usually binds this event to the
  1568.      `internal-select-frame' function, so that characters typed at a
  1569.      frame apply to that frame's selected window.
  1570.      If the user switches frames in the middle of a key sequence, then
  1571.      Emacs delays the `switch-frame' event until the key sequence is
  1572.      over.  For example, suppose `C-c C-a' is a key sequence in the
  1573.      current buffer's keymaps.  If the user types `C-c', moves the
  1574.      mouse to another frame, and then types `C-a', `read-key-sequence'
  1575.      returns the sequence `"\C-c\C-a"', and the next call to
  1576.      `read-event' or `read-key-sequence' will return the `switch-frame'
  1577.      event.
  1578. Working with Input Events
  1579. =========================
  1580.    * Functions which work with key sequences now handle non-character
  1581.      events.  Functions like `define-key', `global-set-key', and
  1582.      `local-set-key' used to accept strings representing key sequences;
  1583.      now, since events may be arbitrary lisp objects, they also accept
  1584.      vectors.  The function `read-key-sequence' may return a string or a
  1585.      vector, depending on whether or not the sequence read contains only
  1586.      characters.
  1587.      List events may be represented by the symbols at their head; to
  1588.      bind clicks of the left mouse button, you need only present the
  1589.      symbol `mouse-1', not an entire mouse click event.  If you do put
  1590.      an event which is a list in a key sequence, only the event's head
  1591.      symbol is used in key lookups.
  1592.      For example, to globally bind the left mouse button to the function
  1593.      `mouse-set-point', you could evaluate this:
  1594.           (global-set-key [mouse-1] 'mouse-set-point)
  1595.      To bind the sequence `C-c F1' to the command `tex-view' in
  1596.      `tex-mode-map', you could evaluate this:
  1597.           (define-key tex-mode-map [?\C-c f1] 'tex-view)
  1598.      To find the binding for the function key labeled NEXT in
  1599.      `minibuffer-local-map', you could evaluate this:
  1600.           (lookup-key minibuffer-local-map [next])
  1601.                => next-history-element
  1602.      If you call the function `read-key-sequence' and then press `C-x
  1603.      C-F5', here is how it behaves:
  1604.           (read-key-sequence "Press `C-x C-F5': ")
  1605.                => [24 C-f5]
  1606.      Note that `24' is the character `C-x'.
  1607.    * The documentation functions (`single-key-description',
  1608.      `key-description', etc.) now handle the new event types.  Wherever
  1609.      a string of keyboard input characters was acceptable in previous
  1610.      versions of Emacs, a vector of events should now work.
  1611.    * Special parts of a window can have their own bindings for mouse
  1612.      events.
  1613.      When mouse events occur in special parts of a window, such as a
  1614.      mode line or a scroll bar, the event itself shows nothing
  1615.      special--only the symbol that would normally represent that mouse
  1616.      button and modifier keys.  The information about the screen region
  1617.      is kept in other parts of the event list.  But `read-key-sequence'
  1618.      translates this information into imaginary prefix keys, all of
  1619.      which are symbols: `mode-line', `vertical-line', and
  1620.      `vertical-scroll-bar'.
  1621.      For example, if you call `read-key-sequence' and then click the
  1622.      mouse on the window's mode line, this is what happens:
  1623.           (read-key-sequence "Click on the mode line: ")
  1624.                => [mode-line (mouse-1 (#<window 6 on NEWS> mode-line
  1625.                                         (40 . 63) 5959987))]
  1626.      You can define meanings for mouse clicks in special window regions
  1627.      by defining key sequences using these imaginary prefix keys.  For
  1628.      example, here is how to bind the third mouse button on a window's
  1629.      mode line delete the window:
  1630.           (global-set-key [mode-line mouse-3] 'mouse-delete-window)
  1631.      Here's how to bind the middle button (modified by META) on the
  1632.      vertical line at the right of a window to scroll the window to the
  1633.      left.
  1634.           (global-set-key [vertical-line M-mouse-2] 'scroll-left)
  1635.    * Decomposing an event symbol.
  1636.      Each symbol used to identify a function key or mouse button has a
  1637.      property named `event-symbol-elements', which is a list containing
  1638.      an unmodified version of the symbol, followed by modifiers the
  1639.      symbol name contains.  The modifiers are symbols; they include
  1640.      `shift', `control', and `meta'.  In addition, a mouse event symbol
  1641.      has one of `click', `drag', and `down'.  For example:
  1642.           (get 'f5 'event-symbol-elements)
  1643.                => (f5)
  1644.           (get 'C-f5 'event-symbol-elements)
  1645.                => (f5 control)
  1646.           (get 'M-S-f5 'event-symbol-elements)
  1647.                => (f5 meta shift)
  1648.           (get 'mouse-1 'event-symbol-elements)
  1649.                => (mouse-1 click)
  1650.           (get 'down-mouse-1 'event-symbol-elements)
  1651.                => (mouse-1 down)
  1652.      Note that the `event-symbol-elements' property for a mouse click
  1653.      explicitly contains `click', but the event symbol name itself does
  1654.      not contain `click'.
  1655.    * Use `read-event' to read input if you want to accept any kind of
  1656.      event.  The old function `read-char' now discards events other than
  1657.      keyboard characters.
  1658.    * `last-command-char' and `last-input-char' can now hold any kind of
  1659.      event.
  1660.    * The new variable `unread-command-events' is much like
  1661.      `unread-command-char'.  Its value is a list of events of any type,
  1662.      to be processed as command input in order of appearance in the
  1663.      list.
  1664.    * The function `this-command-keys' may return a string or a vector,
  1665.      depending on whether or not the sequence read contains only
  1666.      characters.  You may need to upgrade code which uses this function.
  1667.      The function `recent-keys' now returns a vector of events.  You
  1668.      may need to upgrade code which uses this function.
  1669.    * A keyboard macro's definition can now be either a string or a
  1670.      vector.  All that really matters is what elements it has.  If the
  1671.      elements are all characters, then the macro can be a string;
  1672.      otherwise, it has to be a vector.
  1673.    * The variable `last-event-frame' records which frame the last input
  1674.      event was directed to.  Usually this is the frame that was
  1675.      selected when the event was generated, but if that frame has
  1676.      redirected input focus to another frame, `last-event-frame' is the
  1677.      frame to which the event was redirected.
  1678.    * The interactive specification now allows a new code letter `e' to
  1679.      simplify commands bound to events which are lists.  This code
  1680.      supplies as an argument the complete event object.
  1681.      You can use `e' more than once in a single command's interactive
  1682.      specification.  If the key sequence which invoked the command has
  1683.      N events with parameters, the Nth `e' provides the Nth
  1684.      parameterized event.  Events which are not lists, such as function
  1685.      keys and ASCII keystrokes, do not count where `e' is concerned.
  1686.    * You can extract the starting and ending position values from a
  1687.      mouse button or motion event using the two functions `event-start'
  1688.      and `event-end'.  These two functions return different values for
  1689.      drag and motion events; for click and button-down events, they
  1690.      both return the position of the event.
  1691.    * The position, a returned by `event-start' and `event-end', is a
  1692.      list of this form:
  1693.           (WINDOW BUFFER-POSITION (COL . ROW) TIMESTAMP)
  1694.      You can extract parts of this list with the functions
  1695.      `posn-window', `posn-point', `posn-col-row', and `posn-timestamp'.
  1696.    * The function `scroll-bar-scale' is useful for computing where to
  1697.      scroll to in response to a mouse button event from a scroll bar.
  1698.      It takes two arguments, RATIO and TOTAL, and in effect multiplies
  1699.      them.  We say "in effect" because RATIO is not a number; rather a
  1700.      pair `(NUM . DENOM)'.
  1701.      Here's the usual way to use `scroll-bar-scale':
  1702.           (scroll-bar-scale (posn-col-row (event-start event))
  1703.                             (buffer-size))
  1704. Putting Keyboard Events in Strings
  1705. ==================================
  1706.    In most of the places where strings are used, we conceptualize the
  1707. string as containing text characters--the same kind of characters found
  1708. in buffers or files.  Occasionally Lisp programs use strings which
  1709. conceptually contain keyboard characters; for example, they may be key
  1710. sequences or keyboard macro definitions.  There are special rules for
  1711. how to put keyboard characters into a string, because they are not
  1712. limited to the range of 0 to 255 as text characters are.
  1713.    A keyboard character typed using the META key is called a "meta
  1714. character".  The numeric code for such an event includes the 2**23 bit;
  1715. it does not even come close to fitting in a string.  However, earlier
  1716. Emacs versions used a different representation for these characters,
  1717. which gave them codes in the range of 128 to 255.  That did fit in a
  1718. string, and many Lisp programs contain string constants that use `\M-'
  1719. to express meta characters, especially as the argument to `define-key'
  1720. and similar functions.
  1721.    We provide backward compatibility to run those programs with special
  1722. rules for how to put a keyboard character event in a string.  Here are
  1723. the rules:
  1724.    * If the keyboard event value is in the range of 0 to 127, it can go
  1725.      in the string unchanged.
  1726.    * The meta variants of those events, with codes in the range of
  1727.      2**23 to 2**23+127, can also go in the string, but you must change
  1728.      their numeric values.  You must set the 2**7 bit instead of the
  1729.      2**23 bit, resulting in a value between 128 and 255.
  1730.    * Other keyboard character events cannot fit in a string.  This
  1731.      includes keyboard events in the range of 128 to 255.
  1732.    Functions such as `read-key-sequence' that can construct strings
  1733. containing events follow these rules.
  1734.    When you use the read syntax `\M-' in a string, it produces a code
  1735. in the range of 128 to 255--the same code that you get if you modify
  1736. the corresponding keyboard event to put it in the string.  Thus, meta
  1737. events in strings work consistently regardless of how they get into the
  1738. strings.
  1739.    New programs can avoid dealing with these rules by using vectors
  1740. instead of strings for key sequences when there is any possibility that
  1741. these issues might arise.
  1742.    The reason we changed the representation of meta characters as
  1743. keyboard events is to make room for basic character codes beyond 127,
  1744. and support meta variants of such larger character codes.
  1745. Menus
  1746. =====
  1747.    You can now define menus conveniently as keymaps.  Menus are normally
  1748. used with the mouse, but they can work with the keyboard also.
  1749. Defining Menus
  1750. --------------
  1751.    A keymap is suitable for menu use if it has an "overall prompt
  1752. string", which is a string that appears as an element of the keymap.  It
  1753. should describes the purpose of the menu.  The easiest way to construct
  1754. a keymap with a prompt string is to specify the string as an argument
  1755. when you run `make-keymap' or `make-sparse-keymap'.
  1756.    The individual bindings in the menu keymap should also have prompt
  1757. strings; these strings are the items in the menu.  A binding with a
  1758. prompt string looks like this:
  1759.      (CHAR STRING . REAL-BINDING)
  1760.    As far as `define-key' is concerned, the string is part of the
  1761. character's binding--the binding looks like this:
  1762.      (STRING . REAL-BINDING).
  1763.    However, only REAL-BINDING is used for executing the key.
  1764.    You can also supply a second string, called the help string, as
  1765. follows:
  1766.      (CHAR STRING HELP-STRING . REAL-BINDING)
  1767.    Currently Emacs does not actually use HELP-STRING; it knows only how
  1768. to ignore HELP-STRING in order to extract REAL-BINDING.  In the future
  1769. we hope to make HELP-STRING serve as longer documentation for the menu
  1770. item, available on request.
  1771.    The prompt string for a binding should be short--one or two words.
  1772. Its meaning should describe the command it corresponds to.
  1773.    If REAL-BINDING is `nil', then STRING appears in the menu but cannot
  1774. be selected.
  1775.    If REAL-BINDING is a symbol, and has a non-`nil' `menu-enable'
  1776. property, that property is an expression which controls whether the
  1777. menu item is enabled.  Every time the keymap is used to display a menu,
  1778. Emacs evaluates the expression, and it enables the menu item only if
  1779. the expression's value is non-`nil'.  When a menu item is disabled, it
  1780. is displayed in a "fuzzy" fashion, and cannot be selected with the
  1781. mouse.
  1782. Menus and the Mouse
  1783. -------------------
  1784.    The way to make a menu keymap produce a menu is to make it the
  1785. definition of a prefix key.
  1786.    When the prefix key ends with a mouse event, Emacs handles the menu
  1787. keymap by popping up a visible menu that you can select from with the
  1788. mouse.  When you click on a menu item, the event generated is whatever
  1789. character or symbol has the binding which brought about that menu item.
  1790.    A single keymap can appear as multiple panes, if you explicitly
  1791. arrange for this.  The way to do this is to make a keymap for each
  1792. pane, then create a binding for each of those maps in the main keymap
  1793. of the menu.  Give each of these bindings a prompt string that starts
  1794. with `@'.  The rest of the prompt string becomes the name of the pane.
  1795. See the file `lisp/mouse.el' for an example of this.  Any ordinary
  1796. bindings with prompt strings are grouped into one pane, which appears
  1797. along with the other panes explicitly created for the submaps.
  1798.    You can also get multiple panes from separate keymaps.  The full
  1799. definition of a prefix key always comes from merging the definitions
  1800. supplied by the various active keymaps (minor modes, local, and
  1801. global).  When more than one of these keymaps is a menu, each of them
  1802. makes a separate pane or panes.
  1803. Menus and the Keyboard
  1804. ----------------------
  1805.    When a prefix key ending with a keyboard event (a character or
  1806. function key) has a definition that is a menu keymap, you can use the
  1807. keyboard to choose a menu item.
  1808.    Emacs displays the menu alternatives in the echo area.  If they don't
  1809. all fit at once, type SPC to see the next line of alternatives.  If you
  1810. keep typing SPC, you eventually get to the end of the menu and then
  1811. cycle around to the beginning again.
  1812.    When you have found the alternative you want, type the corresponding
  1813. character--the one whose binding is that alternative.
  1814.    In a menu intended for keyboard use, each menu item must clearly
  1815. indicate what character to type.  The best convention to use is to make
  1816. the character the first letter of the menu item prompt string.  That is
  1817. something users will understand without being told.
  1818. The Menu Bar
  1819. ------------
  1820.    Under X Windows, each frame can have a "menu bar"--a permanently
  1821. displayed menu stretching horizontally across the top of the frame.  The
  1822. items of the menu bar are the subcommands of the fake "function key"
  1823. `menu-bar', as defined by all the active keymaps.
  1824.    To add an item to the menu bar, invent a fake "function key" of your
  1825. own (let's call it KEY), and make a binding for the key sequence
  1826. `[menu-bar KEY]'.  Most often, the binding is a menu keymap, so that
  1827. pressing a button on the menu bar item leads to another menu.
  1828.    In order for a frame to display a menu bar, its `menu-bar-lines'
  1829. property must be greater than zero.  Emacs uses just one line for the
  1830. menu bar itself; if you specify more than one line, the other lines
  1831. serve to separate the menu bar from the windows in the frame.  We
  1832. recommend you try one or two as the `menu-bar-lines' value.
  1833. Keymaps
  1834. =======
  1835.    * The representation of keymaps has changed to support the new event
  1836.      types.  All keymaps now have the form `(keymap ELEMENT ELEMENT
  1837.      ...)'.  Each ELEMENT takes one of the following forms:
  1838.     PROMPT-STRING
  1839.           A string as an element of the keymap marks the keymap as a
  1840.           menu, and serves as the overall prompt string for it.
  1841.     `(KEY . BINDING)'
  1842.           A cons cell binds KEY to DEFINITION.  Here KEY may be any
  1843.           sort of event head--a character, a function key symbol, or a
  1844.           mouse button symbol.
  1845.     VECTOR
  1846.           A vector of 128 elements binds all the ASCII characters; the
  1847.           Nth element holds the binding for character number N.
  1848.     `(t . BINDING)'
  1849.           A cons cell whose CAR is `t' is a default binding; anything
  1850.           not bound by previous keymap elements is given BINDING as its
  1851.           binding.
  1852.           Default bindings are important because they allow a keymap to
  1853.           bind all possible events without having to enumerate all the
  1854.           possible function keys and mouse clicks, with all possible
  1855.           modifier prefixes.
  1856.           The function `lookup-key' (and likewise other functions for
  1857.           examining a key binding) normally report only explicit
  1858.           bindings of the specified key sequence; if there is none,
  1859.           they return `nil', even if there is a default binding that
  1860.           would apply to that key sequence if it were actually typed
  1861.           in.  However, these functions now take an optional argument
  1862.           ACCEPT-DEFAULTS which, if non-`nil', says to consider default
  1863.           bindings.
  1864.           Note that if a vector in the keymap binds an ASCII character
  1865.           to `nil' (thus making it "unbound"), the default binding does
  1866.           not apply to the character.  Think of the vector element as
  1867.           an explicit binding of `nil'.
  1868.           Note also that if the keymap for a minor or major mode
  1869.           contains a default binding, it completely masks out any
  1870.           lower-priority keymaps.
  1871.    * A keymap can now inherit from another keymap.  To do this, make the
  1872.      latter keymap the "tail" of the new one.  Such a keymap looks like
  1873.      this:
  1874.           (keymap BINDINGS... . OTHER-KEYMAP)
  1875.      The effect is that this keymap inherits all the bindings of
  1876.      OTHER-KEYMAP, but can add to them or override them with BINDINGS.
  1877.      Subsequent changes in the bindings of OTHER-KEYMAP *do* affect
  1878.      this keymap.
  1879.      For example,
  1880.           (setq my-mode-map (cons 'keymap text-mode-map))
  1881.      makes a keymap that by default inherits all the bindings of Text
  1882.      mode--whatever they may be at the time a key is looked up.  Any
  1883.      bindings made explicitly in `my-mode-map' override the bindings
  1884.      inherited from Text mode, however.
  1885.    * Minor modes can now have local keymaps.  Thus, a key can act a
  1886.      special way when a minor mode is in effect, and then revert to the
  1887.      major mode or global definition when the minor mode is no longer
  1888.      in effect.  The precedence of keymaps is now: minor modes (in no
  1889.      particular order), then major mode, and lastly the global map.
  1890.      The new `current-minor-mode-maps' function returns a list of all
  1891.      the keymaps of currently enabled minor modes, in the other that
  1892.      they apply.
  1893.      To set up a keymap for a minor mode, add an element to the alist
  1894.      `minor-mode-map-alist'.  Its elements look like this:
  1895.           (SYMBOL . KEYMAP)
  1896.      The keymap KEYMAP is active whenever SYMBOL has a non-`nil' value.
  1897.      Use for SYMBOL the variable which indicates whether the minor
  1898.      mode is enabled.
  1899.      When more than one minor mode keymap is active, their order of
  1900.      precedence is the order of `minor-mode-map-alist'.  But you should
  1901.      design minor modes so that they don't interfere with each other,
  1902.      and if you do this properly, the order will not matter.
  1903.      The function `minor-mode-key-binding' returns a list of all the
  1904.      active minor mode bindings of KEY.  More precisely, it returns an
  1905.      alist of pairs `(MODENAME . BINDING)', where MODENAME is the the
  1906.      variable which enables the minor mode, and BINDING is KEY's
  1907.      definition in that mode.  If KEY has no minor-mode bindings, the
  1908.      value is `nil'.
  1909.      If the first binding is a non-prefix, all subsequent bindings from
  1910.      other minor modes are omitted, since they would be completely
  1911.      shadowed.  Similarly, the list omits non-prefix bindings that
  1912.      follow prefix bindings.
  1913.    * The new function `copy-keymap' copies a keymap, producing a new
  1914.      keymap with the same key bindings in it.  If the keymap contains
  1915.      other keymaps directly, these subkeymaps are copied recursively.
  1916.      If you want to, you can define a prefix key with a binding that is
  1917.      a symbol whose function definition is another keymap.  In this
  1918.      case, `copy-keymap' does not look past the symbol; it doesn't copy
  1919.      the keymap inside the symbol.
  1920.    * `substitute-key-definition' now accepts an optional fourth
  1921.      argument, which is a keymap to use as a template.
  1922.           (substitute-key-definition olddef newdef keymap oldmap)
  1923.      finds all characters defined in OLDMAP as OLDDEF, and defines them
  1924.      in KEYMAP as NEWDEF.
  1925.      In addition, this function now operates recursively on the keymaps
  1926.      that define prefix keys within KEYMAP and OLDMAP.
  1927. Minibuffer Features
  1928. ===================
  1929.    The minibuffer input functions `read-from-minibuffer' and
  1930. `completing-read' have new features.
  1931. Minibuffer History
  1932. ------------------
  1933.    A new optional argument HIST specifies which history list to use.
  1934. If you specify a variable (a symbol), that variable is the history
  1935. list.  If you specify a cons cell `(VARIABLE . STARTPOS)', then
  1936. VARIABLE is the history list variable, and STARTPOS specifies the
  1937. initial history position (an integer, counting from zero which
  1938. specifies the most recent element of the history).
  1939.    If you specify STARTPOS, then you should also specify that element
  1940. of the history as INITIAL-INPUT, for consistency.
  1941.    If you don't specify HIST, then the default history list
  1942. `minibuffer-history' is used.  Other standard history lists that you
  1943. can use when appropriate include `query-replace-history',
  1944. `command-history', and `file-name-history'.
  1945.    The value of the history list variable is a list of strings, most
  1946. recent first.  You should set a history list variable to `nil' before
  1947. using it for the first time.
  1948.    `read-from-minibuffer' and `completing-read' add new elements to the
  1949. history list automatically, and provide commands to allow the user to
  1950. reuse items on the list.  The only thing your program needs to do to
  1951. use a history list is to initialize it and to pass its name to the
  1952. input functions when you wish.  But it is safe to modify the list by
  1953. hand when the minibuffer input functions are not using it.
  1954. Other Minibuffer Features
  1955. -------------------------
  1956.    The INITIAL argument to `read-from-minibuffer' and other minibuffer
  1957. input functions can now be a cons cell `(STRING . POSITION)'.  This
  1958. means to start off with STRING in the minibuffer, but put the cursor
  1959. POSITION characters from the beginning, rather than at the end.
  1960.    In `read-no-blanks-input', the INITIAL argument is now optional; if
  1961. it is omitted, the initial input string is the empty string.
  1962. New Features for Defining Commands
  1963. ==================================
  1964.    * If the interactive specification begins with `@', this means to
  1965.      select the window under the mouse.  This selection takes place
  1966.      before doing anything else with the command.
  1967.      You can use both `@' and `*' together in one command; they are
  1968.      processed in order of appearance.
  1969.    * Prompts in an interactive specification can incorporate the values
  1970.      of the preceding arguments.  Emacs replaces `%'-sequences (as used
  1971.      with the `format' function) in the prompt with the interactive
  1972.      arguments that have been read so far.  For example, a command with
  1973.      this interactive specification
  1974.           (interactive "sReplace: \nsReplace %s with: ")
  1975.      prompts for the first argument with `Replace: ', and then prompts
  1976.      for the second argument with `Replace FOO with: ', where FOO is
  1977.      the string read as the first argument.
  1978.    * If a command name has a property `enable-recursive-minibuffers'
  1979.      which is non-`nil', then the command can use the minibuffer to read
  1980.      arguments even if it is invoked from the minibuffer.  The
  1981.      minibuffer command `next-matching-history-element' (normally bound
  1982.      to `M-s' in the minibuffer) uses this feature.
  1983. New Features for Reading Input
  1984. ==============================
  1985.    * The function `set-input-mode' now takes four arguments.  The last
  1986.      argument is optional.  Their names are INTERRUPT, FLOW, META and
  1987.      QUIT.
  1988.      The argument INTERRUPT says whether to use interrupt-driven input.
  1989.      Non-`nil' means yes, and `nil' means no (use CBREAK mode).
  1990.      The argument FLOW says whether to enable terminal flow control.
  1991.      Non-`nil' means yes.
  1992.      The argument META controls support for input character codes above
  1993.      127.  If META is `t', Emacs converts characters with the 8th bit
  1994.      set into Meta characters.  If META is `nil', Emacs disregards the
  1995.      8th bit; this is necessary when the terminal uses it as a parity
  1996.      bit.  If META is neither `t' nor `nil', Emacs uses all 8 bits of
  1997.      input unchanged.  This is good for terminals using European 8-bit
  1998.      character sets.
  1999.      If QUIT non-`nil', it is the character to use for quitting.
  2000.      (Normally this is `C-g'.)
  2001.    * The variable `meta-flag' has been deleted; use `set-input-mode' to
  2002.      enable or disable support for a META key.  This change was made
  2003.      because `set-input-mode' can send the terminal the appropriate
  2004.      commands to enable or disable operation of the META key.
  2005.    * The new variable `extra-keyboard-modifiers' lets Lisp programs
  2006.      "press" the modifier keys on the keyboard.  The value is a bit
  2007.      mask:
  2008.     1
  2009.           The SHIFT key.
  2010.     2
  2011.           The LOCK key.
  2012.     4
  2013.           The CTL key.
  2014.     8
  2015.           The META key.
  2016.      When you use X windows, the program can press any of the modifier
  2017.      keys in this way.  Otherwise, only the CTL and META keys can be
  2018.      virtually pressed.
  2019.    * You can use the new function `keyboard-translate' to set up
  2020.      `keyboard-translate-table' conveniently.
  2021.    * Y-or-n questions using the `y-or-n-p' function now accept `C-]'
  2022.      (usually mapped to `abort-recursive-edit') as well as `C-g' to
  2023.      quit.
  2024.    * The variable `num-input-keys' is the total number of key sequences
  2025.      that the user has typed during this Emacs session.
  2026.    * A new Lisp variable, `function-key-map', holds a keymap which
  2027.      describes the character sequences sent by function keys on an
  2028.      ordinary character terminal.  This uses the same keymap data
  2029.      structure that is used to hold bindings of key sequences, but it
  2030.      has a different meaning: it specifies translations to make while
  2031.      reading a key sequence.
  2032.      If `function-key-map' "binds" a key sequence K to a vector V, then
  2033.      when K appears as a subsequence *anywhere* in a key sequence, it
  2034.      is replaced with V.
  2035.      For example, VT100 terminals send `ESC O P' when the "keypad" PF1
  2036.      key is pressed.  Thus, on a VT100, `function-key-map' should
  2037.      "bind" that sequence to `[pf1]'.  This specifies translation of
  2038.      `ESC O P' into PF1 anywhere in a key sequence.
  2039.      Thus, typing `C-c PF1' sends the character sequence `C-c ESC O P',
  2040.      but `read-key-sequence' translates this back into `C-c PF1', which
  2041.      it returns as the vector `[?\C-c PF1]'.
  2042.      Entries in `function-key-map' are ignored if they conflict with
  2043.      bindings made in the minor mode, local, or global keymaps.
  2044.      The value of `function-key-map' is usually set up automatically
  2045.      according to the terminal's Terminfo or Termcap entry, and the
  2046.      terminal-specific Lisp files.  Emacs comes with a number of
  2047.      terminal-specific files for many common terminals; their main
  2048.      purpose is to make entries in `function-key-map' beyond those that
  2049.      can be deduced from Termcap and Terminfo.
  2050.    * The variable `key-translation-map' works like `function-key-map'
  2051.      except for two things:
  2052.         * `key-translation-map' goes to work after `function-key-map' is
  2053.           finished; it receives the results of translation by
  2054.           `function-key-map'.
  2055.         * `key-translation-map' overrides actual key bindings.
  2056.      The intent of `key-translation-map' is for users to map one
  2057.      character set to another, including ordinary characters normally
  2058.      bound to `self-insert-command'.
  2059. New Syntax Table Features
  2060. =========================
  2061.    * You can use two new functions to move across characters in certain
  2062.      syntax classes.
  2063.      `skip-syntax-forward' moves point forward across characters whose
  2064.      syntax classes are mentioned in its first argument, a string.  It
  2065.      stops when it encounters the end of the buffer, or position LIM
  2066.      (the optional second argument), or a character it is not supposed
  2067.      to skip.  The function `skip-syntax-backward' is similar but moves
  2068.      backward.
  2069.    * The new function `forward-comment' moves point by comments.  It
  2070.      takes one argument, COUNT; it moves point forward across COUNT
  2071.      comments (backward, if COUNT is negative).  If it finds anything
  2072.      other than a comment or whitespace, it stops, leaving point at the
  2073.      far side of the last comment found.  It also stops after
  2074.      satisfying COUNT.
  2075.    * The new variable `words-include-escapes' affects the behavior of
  2076.      `forward-word' and everything that uses it.  If it is non-`nil',
  2077.      then characters in the "escape" and "character quote" syntax
  2078.      classes count as part of words.
  2079.    * There are two new syntax flags for use in syntax tables.
  2080.         - The prefix flag.
  2081.           The `p' flag identifies additional "prefix characters" in Lisp
  2082.           syntax.  You can set this flag with `modify-syntax-entry' by
  2083.           including the letter `p' in the syntax specification.
  2084.           These characters are treated as whitespace when they appear
  2085.           between expressions.  When they appear withing an expression,
  2086.           they are handled according to their usual syntax codes.
  2087.           The function `backward-prefix-chars' moves back over these
  2088.           characters, as well as over characters whose primary syntax
  2089.           class is prefix (`'').
  2090.         - The `b' comment style flag.
  2091.           Emacs can now supports two comment styles simultaneously.
  2092.           (This is for the sake of C++.)  More specifically, it can
  2093.           recognize two different comment-start sequences.  Both must
  2094.           share the same first character; only the second character may
  2095.           differ.  Mark the second character of the `b'-style comment
  2096.           start sequence with the `b' flag.  You can set this flag with
  2097.           `modify-syntax-entry' by including the letter `b' in the
  2098.           syntax specification.
  2099.           The two styles of comment can have different comment-end
  2100.           sequences.  A comment-end sequence (one or two characters)
  2101.           applies to the `b' style if its first character has the `b'
  2102.           flag set; otherwise, it applies to the `a' style.
  2103.           The appropriate comment syntax settings for C++ are as
  2104.           follows:
  2105.          `/'
  2106.                `124b'
  2107.          `*'
  2108.                `23'
  2109.          newline
  2110.                `>b'
  2111.           Thus `/*' is a comment-start sequence for `a' style, `//' is
  2112.           a comment-start sequence for `b' style, `*/' is a comment-end
  2113.           sequence for `a' style, and newline is a comment-end sequence
  2114.           for `b' style.
  2115. The Case Table
  2116. ==============
  2117.    You can customize case conversion using the new case table feature.
  2118. A case table is a collection of strings that specifies the mapping
  2119. between upper case and lower case letters.  Each buffer has its own
  2120. case table.  You need a case table if you are using a language which
  2121. has letters that are not standard ASCII letters.
  2122.    A case table is a list of this form:
  2123.      (DOWNCASE UPCASE CANONICALIZE EQUIVALENCES)
  2124. where each element is either `nil' or a string of length 256.  The
  2125. element DOWNCASE says how to map each character to its lower-case
  2126. equivalent.  The element UPCASE maps each character to its upper-case
  2127. equivalent.  If lower and upper case characters are in 1-1
  2128. correspondence, use `nil' for UPCASE; then Emacs deduces the upcase
  2129. table from DOWNCASE.
  2130.    For some languages, upper and lower case letters are not in 1-1
  2131. correspondence.  There may be two different lower case letters with the
  2132. same upper case equivalent.  In these cases, you need to specify the
  2133. maps for both directions.
  2134.    The element CANONICALIZE maps each character to a canonical
  2135. equivalent; any two characters that are related by case-conversion have
  2136. the same canonical equivalent character.
  2137.    The element EQUIVALENCES is a map that cyclicly permutes each
  2138. equivalence class (of characters with the same canonical equivalent).
  2139.    You can provide `nil' for both CANONICALIZE and EQUIVALENCES, in
  2140. which case both are deduced from DOWNCASE and UPCASE.
  2141.    Here are the functions for working with case tables:
  2142.    `case-table-p' is a predicate that says whether a Lisp object is a
  2143. valid case table.
  2144.    `set-standard-case-table' takes one argument and makes that argument
  2145. the case table for new buffers created subsequently.
  2146. `standard-case-table' returns the current value of the new buffer case
  2147. table.
  2148.    `current-case-table' returns the case table of the current buffer.
  2149. `set-case-table' sets the current buffer's case table to the argument.
  2150.    `set-case-syntax-pair' is a convenient function for specifying a
  2151. pair of letters, upper case and lower case.  Call it with two arguments,
  2152. the upper case letter and the lower case letter.  It modifies the
  2153. standard case table and a few syntax tables that are predefined in
  2154. Emacs.  This function is intended as a subroutine for packages that
  2155. define non-ASCII character sets.
  2156.    Load the library `iso-syntax' to set up the syntax and case table for
  2157. the 256 bit ISO Latin 1 character set.
  2158. New Features for Dealing with Buffers
  2159. =====================================
  2160.    * The new function `buffer-modified-tick' returns a buffer's
  2161.      modification-count that ticks every time the buffer is modified.
  2162.      It takes one optional argument, which is the buffer you want to
  2163.      examine.  If the argument is `nil' (or omitted), the current
  2164.      buffer is used.
  2165.    * `buffer-disable-undo' is a new name for the function formerly
  2166.      known as `buffer-flush-undo'.  This turns off recording of undo
  2167.      information in the buffer given as argument.
  2168.    * The new function `generate-new-buffer-name' chooses a name that
  2169.      would be unique for a new buffer--but does not create the buffer.
  2170.      Give it one argument, a starting name.  It produces a name not in
  2171.      use for a buffer by appending a number inside of `<...>'.
  2172.    * The function `rename-buffer' now takes an optional second argument
  2173.      which tells it that if the specified new name corresponds to an
  2174.      existing buffer, it should use `generate-new-buffer-name' to
  2175.      modify the name to be unique, rather than signaling an error.
  2176.      `rename-buffer' now returns the name to which the buffer was
  2177.      renamed.
  2178.    * The function `list-buffers' now looks at the local variable
  2179.      `list-buffers-directory' in each non-file-visiting buffer, and
  2180.      shows its value where the file would normally go.  Dired sets this
  2181.      variable in each Dired buffer, so the buffer list now shows which
  2182.      directory each Dired buffer is editing.
  2183.    * The function `other-buffer' now takes an optional second argument
  2184.      VISIBLE-OK which, if non-`nil', indicates that buffers currently
  2185.      being displayed in windows may be returned even if there are other
  2186.      buffers not visible.  Normally, `other-buffer' returns a currently
  2187.      visible buffer only as a last resort, if there are no suitable
  2188.      nonvisible buffers.
  2189.    * The hook `kill-buffer-hook' now runs whenever a buffer is killed.
  2190. Local Variables Features
  2191. ========================
  2192.    * If a local variable name has a non-`nil' `permanent-local'
  2193.      property, then `kill-all-local-variables' does not kill it.  Such
  2194.      local variables are "permanent"--they remain unchanged even if you
  2195.      select a different major mode.
  2196.      Permanent locals are useful when they have to do with where the
  2197.      file came from or how to save it, rather than with how to edit the
  2198.      contents.
  2199.    * The function `make-local-variable' now never changes the value of
  2200.      the variable that it makes local.  If the variable had no value
  2201.      before, it still has no value after becoming local.
  2202.    * The new function `default-boundp' tells you whether a variable has
  2203.      a default value (as opposed to being unbound in its default
  2204.      value).  If `(default-boundp 'foo)' returns `nil', then
  2205.      `(default-value 'foo)' would get an error.
  2206.      `default-boundp' is to `default-value' as `boundp' is to
  2207.      `symbol-value'.
  2208.    * The special forms `defconst' and `defvar', when the variable is
  2209.      local in the current buffer, now set the variable's default value
  2210.      rather than its local value.
  2211. New Features for Subprocesses
  2212. =============================
  2213.    * `call-process' and `call-process-region' now return a value that
  2214.      indicates how the synchronous subprocess terminated.  It is either
  2215.      a number, which is the exit status of a process, or a signal name
  2216.      represented as a string.
  2217.    * `process-status' now returns `open' and `closed' as the status
  2218.      values for network connections.
  2219.    * The standard asynchronous subprocess features work on VMS now, and
  2220.      the special VMS asynchronous subprocess functions have been
  2221.      deleted.
  2222.    * You can use the transaction queue feature for more convenient
  2223.      communication with subprocesses using transactions.
  2224.      Call `tq-create' to create a transaction queue communicating with a
  2225.      specified process.  Then you can call `tq-enqueue' to send a
  2226.      transaction.  `tq-enqueue' takes these five arguments:
  2227.           (tq-enqueue TQ QUESTION REGEXP CLOSURE FN)
  2228.      TQ is the queue to use.  (Specifying the queue has the effect of
  2229.      specifying the process to talk to.)  The argument QUESTION is the
  2230.      outgoing message which starts the transaction.  The argument FN is
  2231.      the function to call when the corresponding answer comes back; it
  2232.      is called with two arguments: CLOSURE, and the answer received.
  2233.      The argument REGEXP is a regular expression to match the entire
  2234.      answer; that's how `tq-enqueue' tells where the answer ends.
  2235.      Call `tq-close' to shut down a transaction queue and terminate its
  2236.      subprocess.
  2237.    * The function `signal-process' sends a signal to process PID, which
  2238.      need not be a child of Emacs.  The second argument SIGNAL
  2239.      specifies which signal to send; it should be an integer.
  2240. New Features for Dealing with Times And Time Delays
  2241. ===================================================
  2242.    * The new function `current-time' returns the system's time value as
  2243.      a list of three integers: `(HIGH LOW MICROSEC)'.  The integers
  2244.      HIGH and LOW combine to give the number of seconds since 0:00
  2245.      January 1, 1970, which is HIGH * 2**16 + LOW.
  2246.      MICROSEC gives the microseconds since the start of the current
  2247.      second (or 0 for systems that return time only on the resolution
  2248.      of a second).
  2249.    * The function `current-time-string' accepts an optional argument
  2250.      TIME-VALUE.  If given, this specifies a time to format instead of
  2251.      the current time.  The argument should be a cons cell containing
  2252.      two integers, or a list whose first two elements are integers.
  2253.      Thus, you can use times obtained from `current-time' (see above)
  2254.      and from `file-attributes'.
  2255.    * You can now find out the user's time zone using
  2256.      `current-time-zone'.
  2257.      The value has the form `(OFFSET NAME)'.  Here OFFSET is an integer
  2258.      giving the number of seconds ahead of UTC (east of Greenwich).  A
  2259.      negative value means west of Greenwich.  The second element, NAME
  2260.      is a string giving the name of the time zone.  Both elements
  2261.      change when daylight savings time begins or ends; if the user has
  2262.      specified a time zone that does not use a seasonal time
  2263.      adjustment, then the value is constant through time.
  2264.      If the operating system doesn't supply all the information
  2265.      necessary to compute the value, both elements of the list are
  2266.      `nil'.
  2267.      The optional argument TIME-VALUE, if given, specifies a time to
  2268.      analyze instead of the current time.  The argument should be a
  2269.      cons cell containing two integers, or a list whose first two
  2270.      elements are integers.  Thus, you can use times obtained from
  2271.      `current-time' and from `file-attributes'.
  2272.    * `sit-for', `sleep-for' now let you specify the time period in
  2273.      milliseconds as well as in seconds.  The first argument gives the
  2274.      number of seconds, as before, and the optional second argument
  2275.      gives additional milliseconds.  The time periods specified by
  2276.      these two arguments are added together.
  2277.      Not all systems support this; you get an error if you specify
  2278.      nonzero milliseconds and it isn't supported.
  2279.      `sit-for' also accepts an optional third argument NODISP.  If this
  2280.      is non-`nil', `sit-for' does not redisplay.  It still waits for
  2281.      the specified time or until input is available.
  2282.    * `accept-process-output' now accepts a timeout specified by optional
  2283.      second and third arguments.  The second argument specifies the
  2284.      number of seconds, while the third specifies the number of
  2285.      milliseconds.  The time periods specified by these two arguments
  2286.      are added together.
  2287.      Not all systems support this; you get an error if you specify
  2288.      nonzero milliseconds and it isn't supported.
  2289.      The function returns `nil' if the timeout expired before output
  2290.      arrived, or non-`nil' if it did get some output.
  2291.    * You can set up a timer to call a function at a specified future
  2292.      time.  To do so, call `run-at-time', like this:
  2293.           (run-at-time TIME REPEAT FUNCTION ARGS...)
  2294.      Here, TIME is a string saying when to call the function.  The
  2295.      argument FUNCTION is the function to call later, and ARGS are the
  2296.      arguments to give it when it is called.
  2297.      The argument REPEAT specifies how often to repeat the call.  If
  2298.      REPEAT is `nil', there are no repetitions; FUNCTION is called just
  2299.      once, at TIME.  If REPEAT is an integer, it specifies a repetition
  2300.      period measured in seconds.
  2301.      Absolute times may be specified in a wide variety of formats; The
  2302.      form `HOUR:MIN:SEC TIMEZONE MONTH/DAY/YEAR', where all fields are
  2303.      numbers, works; the format that `current-time-string' returns is
  2304.      also allowed.
  2305.      To specify a relative time, use numbers followed by units.  For
  2306.      example:
  2307.     `1 min'
  2308.           denotes 1 minute from now.
  2309.     `1 min 5 sec'
  2310.           denotes 65 seconds from now.
  2311.     `1 min 2 sec 3 hour 4 day 5 week 6 fortnight 7 month 8 year'
  2312.           denotes exactly 103 months, 123 days, and 10862 seconds from
  2313.           now.
  2314.      If TIME is an integer, that specifies a relative time measured in
  2315.      seconds.
  2316.    To cancel the requested future action, pass the value that
  2317. `run-at-time' returned to the function `cancel-timer'.
  2318. Profiling Lisp Programs
  2319. =======================
  2320.    You can now make execution-time profiles of Emacs Lisp programs using
  2321. the `profile' library.  See the file `profile.el' for instructions; if
  2322. you have written a Lisp program big enough to be worth profiling, you
  2323. can surely understand them.
  2324. New Features for Lisp Debuggers
  2325. ===============================
  2326.    * You can now specify which kinds of errors should invoke the Lisp
  2327.      debugger by setting the variable `debug-on-error' to a list of
  2328.      error conditions.  For example, if you set it to the list
  2329.      `(void-variable)', then only errors about a variable that has no
  2330.      value invoke the debugger.
  2331.    * The variable `command-debug-status' is used by Lisp debuggers.  It
  2332.      records the debugging status of current interactive command.  Each
  2333.      time a command is called interactively, this variable is bound to
  2334.      `nil'.  The debugger can set this variable to leave information for
  2335.      future debugger invocations during the same command.
  2336.      The advantage of this variable over some other variable in the
  2337.      debugger itself is that the data will not be visible for any other
  2338.      command invocation.
  2339.    * The function `backtrace-frame' is intended for use in Lisp
  2340.      debuggers.  It returns information about what a frame on the Lisp
  2341.      call stack is doing.  You specify one argument, which is the
  2342.      number of stack frames to count up from the current execution
  2343.      point.
  2344.      If that stack frame has not evaluated the arguments yet (or is a
  2345.      special form), the value is `(nil FUNCTION ARG-FORMS...)'.
  2346.      If that stack frame has evaluated its arguments and called its
  2347.      function already, the value is `(t FUNCTION ARG-VALUES...)'.
  2348.      In the return value, FUNCTION is whatever was supplied as CAR of
  2349.      evaluated list, or a `lambda' expression in the case of a macro
  2350.      call.  If the function has a `&rest' argument, that is represented
  2351.      as the tail of the list ARG-VALUES.
  2352.      If the argument is out of range, `backtrace-frame' returns `nil'.
  2353. Memory Allocation Changes
  2354. =========================
  2355.    The list that `garbage-collect' returns now has one additional
  2356. element.  This is a cons cell containing two numbers.  It gives
  2357. information about the number of used and free floating point numbers,
  2358. much as the first element gives such information about the number of
  2359. used and free cons cells.
  2360.    The new function `memory-limit' returns an indication of the last
  2361. address allocated by Emacs.  More precisely, it returns that address
  2362. divided by 1024.  You can use this to get a general idea of how your
  2363. actions affect the memory usage.
  2364. Hook Changes
  2365. ============
  2366.    * Expanding an abbrev first runs the new hook
  2367.      `pre-abbrev-expand-hook'.
  2368.    * The editor command loop runs the normal hook `pre-command-hook'
  2369.      before each command, and runs `post-command-hook' after each
  2370.      command.
  2371.    * Auto-saving runs the new hook `auto-save-hook' before actually
  2372.      starting to save any files.
  2373.    * The new variable `revert-buffer-insert-file-contents-function'
  2374.      holds a function that `revert-buffer' now uses to read in the
  2375.      contents of the reverted buffer--instead of calling
  2376.      `insert-file-contents'.
  2377.    * The variable `lisp-indent-hook' has been renamed to
  2378.      `lisp-indent-function'.
  2379.    * The variable `auto-fill-hook' has been renamed to
  2380.      `auto-fill-function'.
  2381.    * The variable `blink-paren-hook' has been renamed to
  2382.      `blink-paren-function'.
  2383.    * The variable `temp-buffer-show-hook' has been renamed to
  2384.      `temp-buffer-show-function'.
  2385.    * The variable `suspend-hook' is now a normal hook.  It used to be a
  2386.      special kind of hook; its value had to be a single function, and
  2387.      if the function returned a non-`nil' value, then suspension was
  2388.      inhibited.
  2389.    * The new function `add-hook' provides a handy way to add a function
  2390.      to a hook variable.  For example,
  2391.           (add-hook 'text-mode-hook 'my-text-hook-function)
  2392.      arranges to call `my-text-hook-function' when entering Text mode
  2393.      or related modes.
  2394.      `add-hook' takes an optional third argument which says to add the
  2395.      new hook function at the end of the list (normally, it goes at the
  2396.      beginning).
  2397.